Now want to directly behind the website links to add an API to access the interface
Now can use HTTP access, page interface is normal, normal interface using HTTPS access page, this is the reason why
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: 1 m;
Ssl_session_timeout 5 m;
Ssl_ciphers ECDHE - RSA - either AES128 - GCM - SHA256: ECDHE: ECDH: AES: HIGH:! NULL:! ANULL:! MD5:! ADH:! RC4. # using this encryption suite,
Ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
Ssl_prefer_server_ciphers on;
The location/{
Root/root/vue - my/dist.
Try_files $$uri uri//index. The HTML last;
The index index. HTML;
}
The 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;
}
}
CodePudding user response:
Do you have any man,,