0

ubuntu nginx通过certbot安装Let's Encrypt https证书

neo created at6 years ago view count: 2400

cerbot 能够简化Let's Encrypt安装https证书和配置nginx的过程。

安装certbot

$ sudo apt-get update
$ sudo apt-get install software-properties-common
$ sudo add-apt-repository ppa:certbot/certbot
$ sudo apt-get update
$ sudo apt-get install python-certbot-nginx 

自动下载证书并配置nginx

$ sudo certbot --nginx

定期更新证书

由于Let's Encrypt 的https证书有过期时间,所以需要到期执行下更新, 可以手动执行下面的命令, 或者加到crontab里面定期更新。

certbot renew 
report
回复