apache 监听 127.0.0.1:8080 用 nginx 监听 0.0.0.0:80 反向代理到 127.0.0.1:8080,apache 获取请求的域名是 127.0.0.1:8080 没办法获取 nginx 代理的域名,这怎么办,业务需要 apache 获取域名,因为要弄子域名根据子域名进行处理
1
learningman 2021-02-02 11:29:15 +08:00 via Android
X-Forward-For 头部
或者你 nginx 反代的时候 proxy_hostname(好像是这个) |
2
julyclyde 2021-02-04 11:38:42 +08:00
proxy_set_header
|