For example two domain name called aaa.com and bbb.com
I want the user to either visit http://aaa.com or https://aaa.com or http://www.aaa.com or https://www.aaa.com or http://www.bbb.com, all jump to https://bbb.com
After using nginx configuration, however, suggests that "your connection is not intimate connection", as shown in the figure below,
I am in nginx configuration is as follows:
Server {
Listen, 80;
Server_name bbb.com aaa.com;
The return of 301 https://www.bbb.com$request_uri;
}
Server {
listen 443 ssl;
Server_name bbb.com;
SSL on;
Ssl_certificate/etc/nginx/cert/www.bbb.com.pem;
Ssl_certificate_key/etc/nginx/cert/www.bbb.com.key;
Ssl_session_timeout 5 m;
Ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
Ssl_ciphers ECDHE - RSA - either AES128 - GCM - SHA256: HIGH:! ANULL:! MD5:! RC4:! DHE;
Ssl_prefer_server_ciphers on;
Access_log/data/logs/nginx/bbb_access log;
Error_log/data/logs/nginx/bbb_error log;
The location/{
Proxy_pass http://0.0.0.0:8091;
proxy_set_header Host $host;
Proxy_set_header X - Real - IP $remote_addr;
Proxy_set_header X - Forwarded - For $proxy_add_x_forwarded_for;
}
The location/static/{
Alias/WWW/jizhi2020/jizhi_news collected_static/;
}
}
Which tall person help to have a look, where configuration has a problem, how to modify? Thank you very much!
CodePudding user response:
Where the application is HTTPS certificate? This is a question of browsers don't trust the certificate with jump no relationship between the two domains