如果遇到手动续订证书(certbot renew)没有问题,但是使用定时任务自动续订不上。
直接上命令
certbot renew --quiet --nginx --nginx-ctl /usr/sbin/nginx --nginx-server-root /etc/nginx && systemctl reload nginx
--nginx-ctl 根据服务器情况,指定 nginx二进制文件 所在位置
--nginx-server-root 根据服务器情况,指定 nginx配置 所在位置(nginx.conf所在目录)
搞定。