no way to compare when less than two revisions
差異處
這裏顯示兩個版本的差異處。
— | tech:ssl_letsencrypt:cf_centos7 [2021/06/23 22:38] (目前版本) – 建立 jonathan | ||
---|---|---|---|
行 1: | 行 1: | ||
+ | ==== CentOS 7 ==== | ||
+ | * 安裝 DNS CloudFlare Plugin< | ||
+ | yum install python2-certbot-dns-cloudflare | ||
+ | </ | ||
+ | * 建立 / | ||
+ | # Cloudflare API credentials used by Certbot | ||
+ | dns_cloudflare_email = [email protected] | ||
+ | dns_cloudflare_api_key = 0123456789abcdef0123456789abcdef01234567 | ||
+ | </ | ||
+ | * 設定保護權限 <code sh> | ||
+ | chmod 600 / | ||
+ | </ | ||
+ | * 進行申請新憑證 Exp. example.com <code sh> | ||
+ | / | ||
+ | --dns-cloudflare \ | ||
+ | --dns-cloudflare-credentials / | ||
+ | --dns-cloudflare-propagation-seconds 10 \ | ||
+ | -d example.com | ||
+ | </ | ||
+ | * 進行定期更新憑證 Exp. example.com <code sh> | ||
+ | / | ||
+ | --dns-cloudflare \ | ||
+ | --dns-cloudflare-credentials / | ||
+ | --dns-cloudflare-propagation-seconds 10 | ||
+ | </ | ||
+ | * 設定每天自動檢查更新 | ||
+ | - 建立 / | ||
+ | vi / | ||
+ | / | ||
+ | --dns-cloudflare \ | ||
+ | --dns-cloudflare-credentials / | ||
+ | --dns-cloudflare-propagation-seconds 10 | ||
+ | </ | ||
+ | chmod a+x / | ||
+ | </ | ||
+ | - 設定 / | ||
+ | vi / | ||
+ | : | ||
+ | # let's encrypt | ||
+ | 35 2 * * * root / | ||
+ | </ | ||
+ | systemctl restart crond | ||
+ | </ | ||