CentOS is too old, yum packages are too old, fuck U CentOS. I’ll move to Debian now.
Preparations
- CentOS 7
- nginx (have configured the HTTP site already)
Deploy
Install Certbot, the Let’s Encrypt client
|
|
Check certbot version:
|
|
And there should print the certbot version.
Deploy HTTPS for Nginx site
|
|
Follow the instructions, type in the email address, agree the agreements, and not to receive advertising mails.
Reload nginx:
|
|
And the HTTPS is deployed.
Verify the HTTPS certificate
Open <yoursite.com> to verify HTTPS.
Auto renew HTTPS certificate
The validity of SSL certificate assigned by Let’s Encrypt is 90 days. So we need to set a crontab timer to update the certificate automatically.
Verify whether we can update the certificate manually fisrt:
|
|
Set crontab timer:
|
|
Update the certificate at 3:15 am every day:
|
|
Check crontab configuration:
|
|