[[proxies]]
name = "web"
type = "http"
localPort = 8086
customDomains = ["www.baidu.com"]
transport.proxyProtocolVersion = "v2"
前段nginx 设置:
location / {
proxy_ssl_server_name on;
proxy_pass http://127.0.0.1:8090;
root html;
index index.html index.htm;
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 REMOTE-HOST $remote_addr;
add_header X-Cache $upstream_cache_status;expires 12h;
}
后端nginx设置
server {
listen 8086 proxy_protocol;
server_name 127.0.0.1;
root "D:/WWW/www.baidu‘’.com";
set_real_ip_from 127.0.0.1;
real_ip_header X-Forwarded-For;
real_ip_recursive on;
声明:本文系互联网搜索百度而收集整理,不以盈利性为目的,文字、图文资料源于互联网且共享于互联网。
如有侵权,请联系 hzy98999#qq.com (#改@) 删除。
如有侵权,请联系 hzy98999#qq.com (#改@) 删除。