今天给新的测试服务器申请let’s encrypt的免费证书,发现安装的方式变了,以前git clone下来就可以申请了,现在需要安装snap,而且centos 7下还有个坑,这里记录下
- 安装&启动snapd服务
yum install snapd
systemctl start snapd
snap install core
- 建立符号链接,这个文档里没有写,如果不做后面安装时会报错
ln -s /var/lib/snapd/snap /snap
- 安装certbot
snap install --classic certbot
- 申请证书(nginx)
certbot certonly --nginx --nginx-server-root=/usr/local/nginx/conf
- 测试renew
certbot renew --dry-run
本文只是个人记录,定时更新证书等请自行设置