[GH-ISSUE #3008] internal application redirection requests #2054

Closed
opened 2026-02-26 07:33:51 +03:00 by kerem · 1 comment
Owner

Originally created by @Suryah07 on GitHub (Jun 17, 2023).
Original GitHub issue: https://github.com/NginxProxyManager/nginx-proxy-manager/issues/3008

My domain is example.com and accessing my app through example.com/app1 and whenever I click on a link through my app it goes to the link example.com/login.html instead of example.com/app1/login.html.
Config :

location /app1/ {
rewrite /app1/(.*) /$1 break;
proxy_pass http://192.168.x.x:80;
}

Originally created by @Suryah07 on GitHub (Jun 17, 2023). Original GitHub issue: https://github.com/NginxProxyManager/nginx-proxy-manager/issues/3008 My domain is example.com and accessing my app through example.com/app1 and whenever I click on a link through my app it goes to the link example.com/login.html instead of example.com/app1/login.html. Config : location /app1/ { rewrite /app1/(.*) /$1 break; proxy_pass [http://192.168.x.x:80](http://192.168.x.x/); }
kerem 2026-02-26 07:33:51 +03:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@SignFinder commented on GitHub (Jul 4, 2023):

What about this one? I am not sure that the problem is related to NPM, might related to incorrect syntax

location ~ ^/app1/ {
proxy_pass http://192.168.x.x;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
}

<!-- gh-comment-id:1620613501 --> @SignFinder commented on GitHub (Jul 4, 2023): What about this one? I am not sure that the problem is related to NPM, might related to incorrect syntax location ~ ^/app1/ { proxy_pass http://192.168.x.x; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; }
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/nginx-proxy-manager-NginxProxyManager#2054
No description provided.