www doesn't work
-
server {
listen 80;
server_name site.com;
location / {
proxy_pass http://localhost:4567/;proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_redirect off; proxy_buffering off; proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection "upgrade"; }
}
What should I do?
-
@osman123 add this block to your nginx conf to redirect www.site.com to site.com
server { listen 80; server_name www.site.com; return 301 http://site.com$request_uri; }
Copyright © 2024 NodeBB | Contributors