用certbot生成Let's Encrypted证书并配置好nginx Posted on 2018-12-27 Edited on 2024-02-03 In tools 123456yum -y install yum-utilsyum-config-manager --enable rhui-REGION-rhel-server-extras rhui-REGION-rhel-server-optionalyum install -y python2-certbot-nginxpip install -U pippip install --upgrade --force-reinstall 'requests==2.6.0' urllib3ln -s /usr/local/nginx/conf /etc/nginx 配置证书 certbot --nginx 根据提示生成证书 配置定时续约证书 crontab -e 10 0,12 * * * python -c 'import random; import time; time.sleep(random.random() * 3600)' && certbot renew 好了没了,就这么简单