fixed: when adding a cert remove previous cert before copying the new one
This fixes when a user (or plugin) has replaced the cert with a symlink; else the symlinked file would be overwritten. This mainly is in the case of a global-cert (plugin) wildcard cert
This commit is contained in:
committed by
Leopold Talirz
parent
57b317b0a4
commit
607b11ab6b
@@ -71,6 +71,7 @@ cmd-certs-set() {
|
||||
fi
|
||||
|
||||
mkdir -p "$APP_SSL_PATH"
|
||||
rm -f "$APP_SSL_PATH/server.crt" "$APP_SSL_PATH/server.key"
|
||||
cp "$CRT_FILE" "$APP_SSL_PATH/server.crt"
|
||||
cp "$KEY_FILE" "$APP_SSL_PATH/server.key"
|
||||
chmod 750 "$APP_SSL_PATH"
|
||||
|
||||
Reference in New Issue
Block a user