ajout du build à l'import de backup

This commit is contained in:
Valentin 2024-05-31 16:31:53 +02:00
parent ac51a99286
commit 8e757fcd3b
1 changed files with 5 additions and 0 deletions

View File

@ -37,11 +37,16 @@ if [[ "$answer" == "y" ]]; then
cms_directory="/var/www/repositories/"$(ls /var/www/repositories | grep cms)
rm -r "${backup_directory}/uploads"
mv -f "${backup_directory}/uploads" "${cms_directory}/"
chown -R www-data:www-data "${cms_directory}/uploads"
rm -r $backup_directory
if [ -f "/var/www/webhook/webhook.sh" ]; then
./var/www/webhook/webhook.sh Backup_import
fi
else
echo -e "${PURPLE}${BOLD}Please import a .tar.gz backup in /home/${username}${RESET}"
fi