From b4ec8839abd21296d19c51878d54e259b2020712 Mon Sep 17 00:00:00 2001 From: Valentin Date: Sat, 30 Nov 2024 20:44:11 +0100 Subject: [PATCH] corrections --- bin/add-site/install_directus.sh | 4 ++-- bin/first-install/setup_ssh.sh | 1 - 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/bin/add-site/install_directus.sh b/bin/add-site/install_directus.sh index 25db52e..599b815 100644 --- a/bin/add-site/install_directus.sh +++ b/bin/add-site/install_directus.sh @@ -61,12 +61,12 @@ if [[ "$answer" == "y" ]]; then echo -e "${PURPLE}${BOLD}Import the .tar.gz archive from your local storage${RESET}" echo -e "${PURPLE}The archive should contain the sql dump and the upload directory${RESET}" echo -e "${PURPLE}Make sure the Website Directus user permissions are setup${RESET}" - echo -e "${BLUE}scp -P ${SSH_PORT} /local/path/to/archive.tar.gz ${USERNAME}@${IP}:/home/${username}/${RESET}" + echo -e "${BLUE}scp -P ${SSH_PORT} /local/path/to/archive.tar.gz ${USERNAME}@${IP}:/home/${USERNAME}/${RESET}" echo -e "${PURPLE}${BOLD}Press any key when done${RESET}" read directus_archive=$(ls /home/${USERNAME}/*.tar.gz); - tar -xzf "${directus_archive}" -C "/home/${USERNAME}/cms.${DOMAIN_NAME}" --strip-components=2 + tar -xzf "${directus_archive}" -C "/home/${USERNAME}/cms.${DOMAIN_NAME}" --strip-components=1 rm "${directus_archive}" sql_dump=$(ls /home/${USERNAME}/cms.${DOMAIN_NAME}/*.sql) docker exec -i "${DOMAIN_NAME}_Directus_DB" mariadb -uroot directus < "${sql_dump}" diff --git a/bin/first-install/setup_ssh.sh b/bin/first-install/setup_ssh.sh index c8ee3a1..ec1e744 100644 --- a/bin/first-install/setup_ssh.sh +++ b/bin/first-install/setup_ssh.sh @@ -8,7 +8,6 @@ read answer if [[ "$answer" == "y" ]]; then echo -e "${PURPLE}${BOLD}Enter the desired SSH port (between 1024 and 65535):${RESET}" read port - # @ TODO : is manually setting port really working ? if [[ "$port" =~ ^[0-9]+$ ]] && [ "$port" -ge 1024 ] && [ "$port" -le 65535 ]; then SSH_PORT=$port else