Created
April 27, 2018 04:28
-
-
Save nk952777/f105bca53816c08c201de24db8714f7f to your computer and use it in GitHub Desktop.
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
upstream backend { | |
server www.facebook.com:443; | |
server www.google.com:443; | |
} | |
server { | |
listen 80; | |
server_name localhost; | |
#charset koi8-r; | |
#access_log /var/log/nginx/host.access.log main; | |
location ~ /(.*) { | |
set $q $1; | |
if ($args) { | |
set $q $1?$args; | |
} | |
proxy_pass https://backend/$q; | |
proxy_set_header Host $host; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment