|
@@ -192,6 +192,8 @@ if [ $LETSENCRYPT_HOSTNAME ]; then
|
192
|
192
|
if [ -f /etc/ssl/private/${LETSENCRYPT_HOSTNAME}.key ]; then
|
193
|
193
|
if [ ! -f /etc/ssl/private/${LETSENCRYPT_HOSTNAME}.key.old ]; then
|
194
|
194
|
mv /etc/ssl/private/${LETSENCRYPT_HOSTNAME}.key /etc/ssl/private/${LETSENCRYPT_HOSTNAME}.key.old
|
|
195
|
+ else
|
|
196
|
+ rm -f /etc/ssl/private/${LETSENCRYPT_HOSTNAME}.key
|
195
|
197
|
fi
|
196
|
198
|
fi
|
197
|
199
|
ln -s /etc/letsencrypt/live/${LETSENCRYPT_HOSTNAME}/privkey.pem /etc/ssl/private/${LETSENCRYPT_HOSTNAME}.key
|
|
@@ -200,6 +202,8 @@ if [ $LETSENCRYPT_HOSTNAME ]; then
|
200
|
202
|
if [ -f /etc/ssl/certs/${LETSENCRYPT_HOSTNAME}.pem ]; then
|
201
|
203
|
if [ ! -f /etc/ssl/certs/${LETSENCRYPT_HOSTNAME}.pem.old ]; then
|
202
|
204
|
mv /etc/ssl/certs/${LETSENCRYPT_HOSTNAME}.pem /etc/ssl/certs/${LETSENCRYPT_HOSTNAME}.pem.old
|
|
205
|
+ else
|
|
206
|
+ rm -f /etc/ssl/certs/${LETSENCRYPT_HOSTNAME}.pem
|
203
|
207
|
fi
|
204
|
208
|
fi
|
205
|
209
|
ln -s /etc/letsencrypt/live/${LETSENCRYPT_HOSTNAME}/fullchain.pem /etc/ssl/certs/${LETSENCRYPT_HOSTNAME}.pem
|