nginx 报错 : [warn] the "ssl" directive is deprecated, use the "listen ... ssl" directive instead

 

最近在给网站配置https证书时发生这个错误,经过排查发现发现nginx提示ssl这个指令已经不建议使用,要使用listen ... ssl替代

nginx 报错 : [warn] the

最开始配置

  server {
    listen 443 ;
    server_name www.xxx.com; 
    ssl on;
    
    root  /www/wwwroot/www.xxx.com/shmyj/public; 
    index  index.html index.htm index.php;
    ssl_certificate  ../cert/2421100_www.xx.com.pem;
    ssl_certificate_key  ../cert/2421100_www.xx.com.key;
    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 / {
        index index.html index.htm index.php;
    }
	}

 

修改为

nginx 报错 : [warn] the

 

你可能感兴趣的:(Linux)