現在網站已經可以用https訪問了 但是介面不行 因為是前端 不太懂這個 大佬們看下我這個配置
現在想直接在網站鏈接后面加個api來訪問介面
現在網站可以用http訪問,頁面介面都是正常,用https訪問頁面正常介面不通,這是什么原因
server {
listen 443 ssl;
server_name localhost;
ssl_certificate cert/3378874_www.lhintro.com.pem;
ssl_certificate_key cert/3378874_www.lhintro.com.key;
ssl_session_cache shared:SSL:1m;
ssl_session_timeout 5m;
ssl_ciphers ECDHE-RSA-AES128-GCM-SHA256:ECDHE:ECDH:AES:HIGH:!NULL:!aNULL:!MD5:!ADH:!RC4; #使用此加密套件。
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
ssl_prefer_server_ciphers on;
location / {
root /root/vue-my/dist;
try_files $uri $uri/ /index.html last;
index index.html;
}
location /api/ {
proxy_set_header Host $http_host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_pass http://127.0.0.1:3080;
}
}
uj5u.com熱心網友回復:
有沒有人啊,,轉載請註明出處,本文鏈接:https://www.uj5u.com/caozuo/59235.html
標籤:專題技術討論區
