po / nginx.conf
sehsapneb's picture
Create nginx.conf
626518f verified
raw
history blame
587 Bytes
server {
listen 7860;
server_name _;
location / {
proxy_pass https://demo.fuclaude.com;
proxy_set_header Host demo.fuclaude.com;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Accept-Encoding "";
# 关键:替换响应中的域名
sub_filter 'demo.fuclaude.com' '$host';
sub_filter_once off;
# 解决 HTTPS 混合内容问题
proxy_redirect ~^https://demo.fuclaude.com(.*) $scheme://$host$1;
}
}