upstream www {
server 127.0.0.1:5000;
}
server {
listen 80;
server_name www.sweetsmartstrongshen.cc;
location / {
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forward-For $proxy_add_x_forwarded_for;
proxy_set_header Host $http_host;
proxy_set_header X-Nginx-Proxy true;
proxy_pass http://www;
proxy_redirect off;
}
location /api/ {
proxy_pass http://support.sweetsmartstrongshen.cc/api/;
}
}
when I visit my website for the first time, due to the server rendering, the interface is not forwarded by nginx, the interface is 404, and then click on the connection is good, what should I do?