Nginx. If Empty URI. If Empty Domain. Location. Regex
I'm using the upstream module for balancing my site. For some reason i have to redirect some requests to a specified server. So in short: i want to redirect domain.com to a specified server, domain.com/anything can be served by the upstream module. So if theres only the domain in开发者_如何学Go the request and nothing else.
location [here_something_i_dont_know]/ {
proxy_pass http://0.0.0.0:9000/;
access_log off;
}
Thanks for ur help!
location = / { proxy_pass http://0.0.0.0:9000/; access_log off; } location / { proxy_pass http://another_upstream; access_log off; }
精彩评论