Fix letsencrypt case when RENEWED_DOMAINS is empty.
This commit is contained in:
parent
0d1bc03665
commit
b7c3d52cd4
@ -13,11 +13,11 @@
|
|||||||
# executable after editing it to your needs.
|
# executable after editing it to your needs.
|
||||||
|
|
||||||
# Set which domain this script will be run for
|
# Set which domain this script will be run for
|
||||||
MY_DOMAIN="example.com"
|
MY_DOMAIN=example.com
|
||||||
# Set the directory that the certificates will be copied to.
|
# Set the directory that the certificates will be copied to.
|
||||||
CERTIFICATE_DIR=/etc/mosquitto/certs
|
CERTIFICATE_DIR=/etc/mosquitto/certs
|
||||||
|
|
||||||
if [ ${RENEWED_DOMAINS} = ${MY_DOMAIN} ]; then
|
if [ "${RENEWED_DOMAINS}" = "${MY_DOMAIN}" ]; then
|
||||||
# Copy new certificate to Mosquitto directory
|
# Copy new certificate to Mosquitto directory
|
||||||
cp ${RENEWED_LINEAGE}/fullchain.pem ${CERTIFICATE_DIR}/server.pem
|
cp ${RENEWED_LINEAGE}/fullchain.pem ${CERTIFICATE_DIR}/server.pem
|
||||||
cp ${RENEWED_LINEAGE}/privkey.pem ${CERTIFICATE_DIR}/server.key
|
cp ${RENEWED_LINEAGE}/privkey.pem ${CERTIFICATE_DIR}/server.key
|
||||||
|
Loading…
Reference in New Issue
Block a user