From e6d24333cb16cba5fcba8dba37b6b7835c55b220 Mon Sep 17 00:00:00 2001 From: Jonas L Date: Wed, 27 Jul 2022 09:51:34 +0200 Subject: [PATCH] fix(installer): clean legacy files before copying (#2002) --- install | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/install b/install index 5eedc216b..9b1d86d85 100755 --- a/install +++ b/install @@ -637,6 +637,11 @@ info "deploying libretime-legacy files" if $LIBRETIME_INSTALL_IN_PLACE; then LEGACY_WEB_ROOT="$SCRIPT_DIR/legacy" else + if [[ -d "$LEGACY_WEB_ROOT" ]]; then + info "cleaning old libretime-legacy files" + rm -Rf "$LEGACY_WEB_ROOT" + fi + mkdir_and_chown "$LIBRETIME_USER" "$LEGACY_WEB_ROOT" cp -R "$SCRIPT_DIR/legacy/." "$LEGACY_WEB_ROOT" chown -R "$LIBRETIME_USER:$LIBRETIME_USER" "$LEGACY_WEB_ROOT"