Closed monkey000 closed 5 years ago
server {
listen 8080;
location / {
proxy_pass http://127.0.0.1:8095;
proxy_redirect off;
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_set_header X-Forwarded-Host $server_name;
proxy_set_header X-Forwarded-Proto https;
proxy_read_timeout 50000s;
client_max_body_size 0;
}
}
I tried the basic configuration without ssl and it works for me on 8080 port for example
Same problem with white screen. I try run it in container with open vpn https://github.com/dperson/openvpn-client To access I need use proxy. -w "http://rats:8095/;/ratsearch
-w "http://rats:8095/main.js;/main.js"
So I should able to access application on http://localhost/ratsearch
And it's not working, I see white screen.
upd
Seems like cors issue:
Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at http://localhost:8095/socket.io/?EIO=3&transport=polling&t=MgoSDGl
Using nginx's proxy_pass to access via domain name will display a blank page. But through the ip: port access can display the normal page. I don't know why there is such a problem. Can anyone provide me some help?
This is my nginx config: