使用letsencrypt给服务器添加https证书

直接进入官网: certbot.eff.org/

选择对应的操作系统, 根据文档操作即可.

以下命令摘自该官网, 本站Ubuntu 16.04.6 +nginx下亲测可行:(其他系统的请自行上官网查看对应安装方法)

sudo apt-get update
sudo apt-get install software-properties-common
sudo add-apt-repository universe
sudo add-apt-repository ppa:certbot/certbot
sudo apt-get update
sudo apt-get install certbot python-certbot-nginx 
sudo certbot --nginx
sudo certbot renew --dry-run

可以看到成功后访问本站,已经成功!

————– 以下是旧的内容, 缺点是配完需要手动启动定时任务更新证书 —————

Can not be more simple, 简单得不能再简单的,letsencrypt——只需一行代码:

git clone https://github.com/certbot/certbot.git && ./certbot/letsencrypt-auto

然后根据提示操作即可

以上是我个人的成功经验,官网的方法是:certbot.eff.org/lets-encrypt/ubunt...

本作品采用《CC 协议》,转载必须注明作者和本文链接
讨论数量: 0
(= ̄ω ̄=)··· 暂无内容!

讨论应以学习和精进为目的。请勿发布不友善或者负能量的内容,与人为善,比聪明更重要!