问题:
$ curl -I http://www.bbs.com/
HTTP/1.1 302
Server: nginx/1.16.0
Date: Tue, 26 Nov 2019 08:00:35 GMT
Location: http://192.168.1.2/index.html
Connection: keep-alive
Cache-Control: no-cache
解决办法:
server {
listen80;
server_name www.bbs.com;
location / {
proxy_pass http://192.168.1.2;
proxy_redirect http://192.168.1.2 http://www.bbs.com;
}