背景:我们的证书是添加在前端的SLB上的,例如,预发对应预发SLB。
需求:要为某个预发应用域名添加证书,以支持https访问。
1、测试环境添加证书
proxy.dasc.com
$ cd /home/sc/bin/letsencrypt
$ ./letsencrypt.sh letsencrypt.conf
$ ./update-pem.sh domainname /home/souche/bin/letsencrypt/output/domainname.pem
2、预发添加证书
devsqa-forwarding-010168053033.hzd
$ cd bin/letsencrypt
$ ./letsencrypt.sh letsencrypt.conf
$ ./update-pem.sh domainname /home/sc/bin/letsencrypt/output/domainname.pem
添加证书过程中遇到403,需要到对应的域名服务器去修改对应nginx的conf文件。例如:
# if ($deny_host) {
# return 403;
# }