每个人的收获。
在nginx-1.13.8
上配置Windows Server
时遇到麻烦。
在reverse_proxy
上添加SSL后,我收到404
工作配置(http):
server {
listen 80;
server_name example.com;
location / {
proxy_pass http://192.168.0.3:80;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $remote_addr;
proxy_set_header X-Forwarded-Proto $scheme;
}
}
使用ssl进行配置:
server {
listen 443 ssl;
server_name example.com;
ssl on;
ssl_certificate ../cert/certcombined.crt;
ssl_certificate_key ../cert/private_rsa.key;
location / {
proxy_pass http://192.168.0.3:80;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $remote_addr;
proxy_set_header X-Forwarded-Proto $scheme;
}
}
192.168.0.3
在Linux上是Apache
抱歉"broken english"