- 积分
- 77
- 威望
-
- 金钱
-
- 注册时间
- 2016-10-15
- 在线时间
- 小时
- 最后登录
- 1970-1-1
|
资料:对于开启了https的用户,未添加https站点的域名,也可以https访问,只是会访问默认的https网站并提示不安全、域名证书不匹配。
开启SSL后https的空主机头的设置复制内容到剪贴板代码:server {
listen 443 default_server;
server_name _;
ssl on;
ssl_certificate 随便设置一个ssl证书;
ssl_certificate_key 随便设置一个ssl证书的key;
return 500;
}
请问军哥:
关于:随便设置一个ssl证书 和 随便设置一个ssl证书的key
我乱打了一堆英文字母(09809jlkjppipoipipipoipoi),重启 nginx报错了,如下:
- [root@iZbp1fgnu2pf6e1wjvotm2Z conf]# lnmp nginx restart
- +-------------------------------------------+
- | Manager for LNMP, Written by Licess |
- +-------------------------------------------+
- | https://lnmp.org |
- +-------------------------------------------+
- Stoping nginx... nginx: [emerg] BIO_new_file("/usr/local/nginx/conf/09809jlkjppipoipipipoipoip") failed (SSL: error:02001002:system library:fopen:No such file or directory:fopen('/usr/local/nginx/conf/09809jlkjppipoipipipoipoip','r') error:2006D080:BIO routines:BIO_new_file:no such file)
- failed. Use force-quit
- Terminating nginx... done
- Starting nginx... nginx: [emerg] BIO_new_file("/usr/local/nginx/conf/09809jlkjppipoipipipoipoip") failed (SSL: error:02001002:system library:fopen:No such file or directory:fopen('/usr/local/nginx/conf/09809jlkjppipoipipipoipoip','r') error:2006D080:BIO routines:BIO_new_file:no such file)
- failed
复制代码
那么开启SSL的,这儿,具体该填啥,能否给个案例,谢谢! |
|