centos7使用certbot报python错误
目录
遇到centos7使用certbot报python错误后的安装方法
获取certbot客户端
wget https://dl.eff.org/certbot-auto
chmod a+x certbot-auto停止nginxyunx
service nginx stop生成证书
./certbot-auto certonly --standalone --email `你的邮箱地址` -d `你的域名地址`
当前网站有多个域名时需在后面增加,例如
./certbot-auto certonly --standalone --email [email protected] -d example.com -d www.example.com查看生产的证书
tree /etc/letsencrypt/live/将证书用于nginx在nginx网站配置文件中增加
###证书位置
ssl_certificate "/etc/letsencrypt/live/example.com/fullchain.pem";
ssl_certificate_key "/etc/letsencrypt/live/example.com/privkey.pem";启动nginx
service nginx start/posts/2017/install-certificates/