Created
April 18, 2017 09:35
-
-
Save Shellbye/adf80f97ab8d657dbfbac6bb72cf13c0 to your computer and use it in GitHub Desktop.
nginx load balance simple demo
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
# nginx_load_balance.conf | |
# https://www.nginx.com/resources/admin-guide/load-balancer/ | |
upstream backend { | |
server 127.0.0.1:8000; | |
server 192.168.1.1; | |
server domain.to.other.server; | |
} | |
server { | |
listen 80; | |
server_name www.domain.com; | |
charset utf-8; | |
location / { | |
proxy_pass http://backend; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment