VPS侦探论坛

标题: 1.4 域名添加ssl失败 [打印本页]

作者: xiaoxue    时间: 2017-6-4 16:46
标题: 1.4 域名添加ssl失败
  1. Create Virtul Host directory......
  2. set permissions of Virtual Host directory......
  3. You select the exist rewrite rule:/usr/local/nginx/conf/wordpress.conf
  4. Test Nginx configure file......
  5. nginx: the configuration file /usr/local/nginx/conf/nginx.conf syntax is ok
  6. nginx: configuration file /usr/local/nginx/conf/nginx.conf test is successful
  7. Reload Nginx......
  8. Gracefully shutting down php-fpm . done
  9. Starting php-fpm  done
  10. You select the exist rewrite rule:/usr/local/nginx/conf/wordpress.conf
  11. Test Nginx configure file......
  12. nginx: the configuration file /usr/local/nginx/conf/nginx.conf syntax is ok
  13. nginx: configuration file /usr/local/nginx/conf/nginx.conf test is successful
  14. Reload Nginx......
  15. /bin/certbot [found]
  16. index-url=http://mirrors.aliyun.com/pypi/simple/
  17. pip.conf exist.
  18. Starting create SSL Certificate use Let's Encrypt...
  19. Saving debug log to /var/log/letsencrypt/letsencrypt.log
  20. Obtaining a new certificate
  21. Performing the following challenges:
  22. http-01 challenge for wwo.cn
  23. http-01 challenge for www.wwo.cn
  24. Using the webroot path /home/wwwroot/wwo.cn for all unmatched domains.
  25. Waiting for verification...
  26. Cleaning up challenges
  27. Failed authorization procedure. www.wwo.cn (http-01): urn:acme:error:connection :: The server could not connect to the client to verify the domain :: Could not connect to www.wwo.cn

  28. IMPORTANT NOTES:
  29. - The following errors were reported by the server:

  30.    Domain: www.wwo.cn
  31.    Type:   connection
  32.    Detail: Could not connect to www.wwo.cn

  33.    To fix these errors, please make sure that your domain name was
  34.    entered correctly and the DNS A record(s) for that domain
  35.    contain(s) the right IP address. Additionally, please check that
  36.    your computer has a publicly routable IP address and that no
  37.    firewalls are preventing the server from communicating with the
  38.    client. If you're using the webroot plugin, you should also verify
  39.    that you are serving files from the webroot path you provided.
  40. Let's Encrypt SSL Certificate create failed!
  41. ================================================
  42. Virtualhost infomation:
  43. Your domain: wwo.cn
  44. Home Directory: /home/wwwroot/wwo.cn
  45. Rewrite: wordpress
  46. Enable log: yes
  47. Create database: no
  48. Create ftp account: no
  49. Enable SSL: yes
  50.   =>Let's Encrypt
复制代码

作者: xiaoxue    时间: 2017-6-4 16:47


已自行搞定!

原因是:
因为之前的1.3版本默认LNMP的虚拟主机里是禁止 . 开头的隐藏文件及目录的,所以访问http://abc.com/.well-known/acme-challenge/**** 这个链接的话返回403错误,所以必须要将对应虚拟主机配置文件里的
location ~ /\.
{
deny all;
}
这段配置删掉或注释掉或在这段配置前面加上
location ~ /.well-known {
allow all;
}
修改保存后重启nginx。

[ 本帖最后由 xiaoxue 于 2017-6-4 17:11 编辑 ]
作者: licess    时间: 2017-6-4 18:22
按错误信息连接不到你服务器上说明解析还没生效或有其他问题




欢迎光临 VPS侦探论坛 (https://bbs.lnmp.com/) Powered by Discuz! X3.4