Created
June 7, 2017 13:49
-
-
Save yickling/ef20f7f1bd8341c2a46db05afe8b4e4d to your computer and use it in GitHub Desktop.
Nginx rewrite path to point back to root
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This will rewrite 1.2.3.4/sub back to 1.2.3.4:3000 | |
location /sub { | |
rewrite /sub(.*) $1 break; | |
proxy_set_header X-Real-IP $remote_addr; | |
proxy_set_header Host $http_host; | |
proxy_pass http://localhost:3000; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment