upstream sync_gateway {
server 127.0.0.1:4985;
}
server {
listen 80;
server_name dl.mydomain.com;
location / {
proxy_pass http://sync_gateway;
proxy_pass_header Accept;
proxy_pass_header Server;
proxy_http_version 1.1;
keepalive_requests 1000;
keepalive_timeout 360s;
proxy_read_timeout 360s;
}
}
Do I need to add any thing else to this?
I know my SG is setup correctly, as requests directly to 127.0.0.1:4985 work fine. But request to 127.0.0.1:80 return 502.
Todd
sudo setsebool httpd_can_network_connect on -P
Then it started working. I don't know enough about Nginx to know if my default setting is different on my setup versus others. I haven't seen anyone report needing to do this.
It might be a good idea to maybe comment on this in the SG/Nginx docs on the web site.
Todd