I'm trying to setup nginx for Node.js/Socket.io + static files, here's my conf :
upstream app_salewhalepro {
server 127.0.0.1:5000;
keepalive 8;
}
# the nginx server instance
server {
listen 0.0.0.0:443;
server_name salewhalepro.com salewhalepro;
access_log /var/log/nginx/salewhalepro.log;
ssl on;
ssl_certificate /etc/ssl/certs/PositiveSSL.ca-bundle.crt;
ssl_certificate_key /etc/ssl/private/salewhalepro.key;
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
location / {
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $http_host;
proxy_set_header X-NginX-Proxy true;
proxy_pass http://app_salewhalepro/;
proxy_redirect off;
}
location /libs {
alias /var/whaleAPI/app/public;
access_log off;
expires max;
}
}
the http address sends me to the default nginx page, which is fine, but the https doesn't work at all, is there anything wrong with my conf? I could swear that it's a copypaste of a working config I use on a different server.
Aucun commentaire:
Enregistrer un commentaire