Let’s Encrypt 免费SSL证书 Debian/Centos6/Centos7 教程

### Debian
apt-get install git

### CentOS 6
yum install centos-release-SCL && yum update
yum install python27
scl enable python27 bash
yum install python27-python-devel python27-python-setuptools python27-python-tools python27-python-virtualenv
yum install augeas-libs dialog gcc libffi-devel openssl-devel python-devel

### CentOS 7
yum install -y git python27
yum install -y augeas-libs dialog gcc libffi-devel openssl-devel python-devel
python -V

###SSL
cd /opt
git clone https://github.com/letsencrypt/letsencrypt
cd letsencrypt
./letsencrypt-auto certonly –server https://acme-v01.api.letsencrypt.org/directory –agree-dev-preview

git clone https://github.com/letsencrypt/letsencrypt
cd letsencrypt
./letsencrypt-auto –verbose
# during beta
./letsencrypt-auto –verbose –agree-dev-preview –server https://acme-v01.api.letsencrypt.org/directory certonly

运行完以上命令会弹出一个蓝色UI窗口,
输入email,
然后同意TOS
输入域名,之后出现“Congratulations! Your certificate and chain have been saved at /etc/letsencrypt/live/你的域名/fullchain.pem.”等提示就是成功了。

接着去/etc/letsencrypt/live/你的域名/文件夹下你会发现4个pem文件,
其中
fullchain.pem就是配置https站点需要使用的crt文件,
privkey.pem就是key文件

One thought on “Let’s Encrypt 免费SSL证书 Debian/Centos6/Centos7 教程

  1. 感谢

发表回复

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