Let’s Encrypt使用certbot-5分钟快速为你的站点开启HTTPS

本文将介绍使用Certbot为站点快速开启HTTPS

本文使用的环境为Ubuntu 16.04 server + Nginx

安装Certbot

在Ubuntu系统中,Certbot团队维护了一个PPA源,你可以将他添加到自己的仓库中。

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 python-certbot-nginx 

开启HTTPS!

在期间脚本会询问,哪些站点需要开启HTTPS,需不需要重定向,按需确认即可

sudo certbot --nginx

自动续约

因为Let's Encrypt证书只有90天,所以最好开启此功能。

sudo certbot renew --dry-run

相关推荐

发表回复

您的电子邮箱地址不会被公开。 必填项已用 * 标注

微信扫一扫,分享到朋友圈

Let’s Encrypt使用certbot-5分钟快速为你的站点开启HTTPS
返回顶部

显示

忘记密码?

显示

显示

获取验证码

Close