You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
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
While reading through #1462 I suspected the issue to be a misconfiguration, which wasn't related to the nginx proxy manager. Since I use a similar setup, I posted my solution. Afterwards, I updated my exact same solution just to realize, that it doesn't work anymore. My setup is as follows:
Add a new proxy host, e.g. my.domain. Forward name and port don't matter as they will be overwritten.
Add a custom location as shown in the below picture. You have to adapt the container name
Save the proxy host and access it. Enter a url that doesn't even exist on the server, like my.domain/doesnotexist, and realize that static_container/en/index.html is returned for this path as well as for every other path. This also replaces all css and js files with the index html.
Adapt the generated nginx config file manually. Change proxy_pass $upstream to proxy_pass http://static_container:80/en/ (which is the same value as assigned to $upstream).
Disable an re-enable the proxy host to reload the configuration. Now my.domain/doesnotexist results in a 404 error as it should, and js and css files for static_container/en/index.html are fetched correctly.
Expected behavior
It should work, as it used to with the previous version.
Operating System
Linux, not applicable for this issue
Additional context
While troubleshooting, I also stumbled upon this stackoverflow thread, which looks really promising
The text was updated successfully, but these errors were encountered:
If I remember correctly using a variable inside proxy_pass instead of a string literal changes how nginx processes the url. If it is a string literal it will append the path after the location, so location /foo/ with a proxy_pass of 1.2.3.4/test and a request to /foo/bar/ will result in a proxy request to 1.2.3.4/test/bar. But when a variable is used, nginx expects the full path in the variable and will not append anything, resulting in all requests being proxied to 1.2.3.4/test without any other data from the path being used.
Uh oh!
There was an error while loading. Please reload this page.
Checklist
jc21/nginx-proxy-manager:latest
docker image?Describe the bug
While reading through #1462 I suspected the issue to be a misconfiguration, which wasn't related to the nginx proxy manager. Since I use a similar setup, I posted my solution. Afterwards, I updated my exact same solution just to realize, that it doesn't work anymore. My setup is as follows:
english.website -> static_container:80/en/
german.website -> static_container:80/de/
I achieved this using a custom location for
/
. This setup was working a few versions back (I don't remember the exact version), and does work again if I update the generated nginx configs manually to revert the commit 6c1ae77#diff-d59b1035c588d4d81d509bb6c436f753aa5256a9cada91f28b6afc55b26d2c6bTo be even more precise, I simply changed
to
proxy_pass http://static_container:80/en/
Nginx Proxy Manager Version
v2.9.9
To Reproduce
Steps to reproduce the behavior:
Add a new proxy host, e.g.
my.domain
. Forward name and port don't matter as they will be overwritten.Add a custom location as shown in the below picture. You have to adapt the container name

Save the proxy host and access it. Enter a url that doesn't even exist on the server, like
my.domain/doesnotexist
, and realize thatstatic_container/en/index.html
is returned for this path as well as for every other path. This also replaces all css and js files with the index html.Adapt the generated nginx config file manually. Change
proxy_pass $upstream
toproxy_pass http://static_container:80/en/
(which is the same value as assigned to$upstream
).Disable an re-enable the proxy host to reload the configuration. Now
my.domain/doesnotexist
results in a 404 error as it should, and js and css files forstatic_container/en/index.html
are fetched correctly.Expected behavior
It should work, as it used to with the previous version.
Operating System
Linux, not applicable for this issue
Additional context
While troubleshooting, I also stumbled upon this stackoverflow thread, which looks really promising
The text was updated successfully, but these errors were encountered: