Merge 78a00e5ae2
into 47506fdb43
This commit is contained in:
commit
4782b147bd
|
@ -74,6 +74,12 @@ env:
|
|||
## If you added the Lets Encrypt template, uncomment below to get a free SSL certificate
|
||||
#LETSENCRYPT_ACCOUNT_EMAIL: me@example.com
|
||||
|
||||
## To use DNS verification with letsencrypt uncomment below and add the relevant environment variables from: https://github.com/acmesh-official/acme.sh/wiki/dnsapi
|
||||
# (cloudflare example)
|
||||
#DISCOURSE_ACME_DNS_MODE: dns_cf
|
||||
#CF_Key: 763eac4f1bcebd8b5c95e9fc50d010b4
|
||||
#CF_Email: user@example.com
|
||||
|
||||
## The http or https CDN address for this Discourse instance (configured to pull)
|
||||
## see https://meta.discourse.org/t/14857 for details
|
||||
#DISCOURSE_CDN_URL: https://discourse-cdn.example.com
|
||||
|
|
|
@ -63,6 +63,12 @@ env:
|
|||
## If you added the Lets Encrypt template, uncomment below to get a free SSL certificate
|
||||
#LETSENCRYPT_ACCOUNT_EMAIL: me@example.com
|
||||
|
||||
## To use DNS verification with letsencrypt uncomment below and add the relevant environment variables from: https://github.com/acmesh-official/acme.sh/wiki/dnsapi
|
||||
# (cloudflare example)
|
||||
#DISCOURSE_ACME_DNS_MODE: dns_cf
|
||||
#CF_Key: 763eac4f1bcebd8b5c95e9fc50d010b4
|
||||
#CF_Email: user@example.com
|
||||
|
||||
## TODO: configure connectivity to the databases
|
||||
DISCOURSE_DB_SOCKET: ''
|
||||
#DISCOURSE_DB_USERNAME: discourse
|
||||
|
|
|
@ -59,7 +59,11 @@ hooks:
|
|||
/usr/sbin/nginx -c /etc/nginx/letsencrypt.conf
|
||||
|
||||
issue_cert() {
|
||||
LE_WORKING_DIR="${LETSENCRYPT_DIR}" $$ENV_LETSENCRYPT_DIR/acme.sh --issue $2 -d $$ENV_DISCOURSE_HOSTNAME --keylength $1 -w /var/www/discourse/public
|
||||
if [ -z $DISCOURSE_ACME_DNS_MODE ]; then
|
||||
LE_WORKING_DIR="${LETSENCRYPT_DIR}" $$ENV_LETSENCRYPT_DIR/acme.sh --issue $2 -d $$ENV_DISCOURSE_HOSTNAME --keylength $1 -w /var/www/discourse/public
|
||||
else
|
||||
LE_WORKING_DIR="${LETSENCRYPT_DIR}" $$ENV_LETSENCRYPT_DIR/acme.sh --dns ${DISCOURSE_ACME_DNS_MODE} --issue $2 -d $$ENV_DISCOURSE_HOSTNAME --keylength $1 -w /var/www/discourse/public
|
||||
fi
|
||||
}
|
||||
|
||||
cert_exists() {
|
||||
|
|
Loading…
Reference in New Issue