Skip to content

Access list working only with "manual" workarounds #3577

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
hans-holgersson opened this issue Feb 22, 2024 · 7 comments
Open

Access list working only with "manual" workarounds #3577

hans-holgersson opened this issue Feb 22, 2024 · 7 comments
Labels

Comments

@hans-holgersson
Copy link

hans-holgersson commented Feb 22, 2024

Checklist

  • Have you pulled and found the error with jc21/nginx-proxy-manager:latest docker image?
    • Yes
  • Are you sure you're not using someone else's docker image?
    • Yes
  • Have you searched for similar issues (both open and closed)?
    • Yes

Describe the bug
Proxy hosts with attached ACLs has strange bahaviour, more exactly ACLs does not work as expected;
I will describe two stirngs of steps, because i think the two has common root cuse

Nginx Proxy Manager Version
v2.11.1

To Reproduce
Steps to reproduce the behavior #1:

  1. create proxy host HOST1
  2. create an ACL
  3. attach ACL to HOST1
  4. disable HOST1
  5. proxy host config is deleted
  6. enable proxy host
  7. proxy host config is created, but it is incorrect, it has a location statement in it like this:
location / {
  # Access Rules: 0 total
  deny all;
  # Access checks must...
  satisfy all;

(satisfy statement has the value as it was set ACL)
8. because of the incorrect location the proxy host does not work - getting error 403;

9.1. open edit Proxy Host and simply save it, without any changes, the location statement is written correctly and proxy host works as expected;

9.2. open edit ACL, and simply save it, without any changes, the location statement is written correctly but poxy host does not work correctly because nginx does not pick up the new config: it must be restarted for example with a killall in container console.

Steps to reproduce the behavior #2:

  1. create proxy host (say HOST1)
  2. create ACL (say ACL1)
  3. attach ACL1 to HOST1
  4. disable proxy host HOST1
  5. proxy host config for HOST1 is deleted
  6. nginx is restarted automatically
    6.1 HOST1 is not working in browser (it is OK because we disabled it, right?)
  7. open to edit ACL1 and simply save it whithout any modification
  8. proxy host config for HOST1 is generated
  9. nginx is not restarted (HOST1 still not working in browser - it is OK until now)
  10. open to edit some another proxy host (say HOST2), and save it
  11. nginx will be restarted
  12. HOST1 is working in browser (it is NOT OK!!! HOST1 is disabled - see step 4.) because of the existence of the previously generated config file (see setp 8.)

Expected behavior
The logic behind the actions generating config files for proxy hosts and reloading nginx should be correlated:

  • if proxy host is modified or edited (and saved) should take in account the attached ACLs too when generating config file;
  • if ACL is edited and saved it should take in account the status of the proxy hosts to which the ALC is attached, and if any real modifcation happned, nginx should be reloaded;

Screenshots

Operating System
Rocky Linux 9.3

Additional context
browser cache was cleared before single every test step

Copy link

github-actions bot commented Sep 3, 2024

Issue is now considered stale. If you want to keep it open, please comment 👍

@github-actions github-actions bot added the stale label Sep 3, 2024
@hans-holgersson
Copy link
Author

Is this resolved in the current "latest"?

@github-actions github-actions bot removed the stale label Oct 28, 2024
@zhouguiheng
Copy link

I encountered the same issue, and had to do step 9.1 to bring the host back.
I set up a new container from scratch for testing, and can consistently reproduce step #1 to #8

@hans-holgersson
Copy link
Author

@zhouguiheng do you use version 2.11.1 or another?

@Wadera
Copy link

Wadera commented Jan 9, 2025

I'm on v2.12.2 and still can reproduce the issue

@zhouguiheng
Copy link

@zhouguiheng do you use version 2.11.1 or another?

Both 2.12.1 and 2.12.2 (latest) have this issue

@hans-holgersson
Copy link
Author

great ...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants