I want my site to be available at mysite.io, with this code I tried to reverse proxy it so it works.
After running this I found out it only works at mysite.io:5000, at my server's ip, and at my server's ip:5000. Basically all possibilities but the desired mysite.io, where did I go wrong? I appreciate any help, this is my first time deploying.
server {
listen 80 default_server;
listen [::]:80 default_server;
root /var/www/html;
index index.html index.htm index.nginx-debian.html;
server_name mysite.io www.mysite.io;
location / {
proxy_pass http://localhost:5000;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
}
}
question from:
https://stackoverflow.com/questions/65928508/reverse-proxy-with-nginx-works-everywhere-but-where-i-want-it-to-work 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…