Nginx 配置443 HTTPS

server {
listen 443 ssl;
server_name localhost;
ssl on;
ssl_certificate D://newlingshou//nginx-1.12.2//keys//2796952_mlub.regentxcx.com.pem;
ssl_certificate_key D://newlingshou//nginx-1.12.2//keys//2796952_mlub.regentxcx.com.key;
ssl_session_cache shared:SSL:1m;
ssl_session_timeout 5m;

    ssl_ciphers  HIGH:!aNULL:!MD5;
    ssl_prefer_server_ciphers  on;

    location / {
        root   html;
        index  index.html index.htm;
    }

location /SaleAideServer {
proxy_pass http://127.0.0.1:8701/saleServer;
root html;
index index.html index.htm;
}

location /SaleAideServer2 {
proxy_pass http://127.0.0.1:8702/saleServer;
root html;
index index.html index.htm;
}
}

关于域名证书,需要申请nginx的子域名证书

关注公众号githubcn,免费获取更多学习视频教程

posted @ 2019-09-10 17:41  软件技术开发  阅读(8889)  评论(0编辑  收藏  举报