From e56daa5f7f565ebc86a9fa58df708bdb8ae662e4 Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Sat, 13 Dec 2014 19:34:22 +0000 Subject: [PATCH] More directory twiddling --- install-freedombone.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/install-freedombone.sh b/install-freedombone.sh index 07dca332..d9c51f46 100755 --- a/install-freedombone.sh +++ b/install-freedombone.sh @@ -909,14 +909,14 @@ function create_restore_script { echo ' fi' >> /usr/bin/$RESTORE_SCRIPT_NAME echo " rsyncrypto -v -d -r $USB_MOUNT/backup/mariadb /root/tempmariadb $USB_MOUNT/backup/mariadb.keys $BACKUP_CERTIFICATE" >> /usr/bin/$RESTORE_SCRIPT_NAME echo ' echo "Get the MariaDB password from the backup"' >> /usr/bin/$RESTORE_SCRIPT_NAME - echo ' if [ ! -f /root/tempmariadb/usb/backup/mariadb/db ]; then' >> /usr/bin/$RESTORE_SCRIPT_NAME + echo ' if [ ! -f /root/tempmariadb/usb/backup/mariadb/tempmariadb/db ]; then' >> /usr/bin/$RESTORE_SCRIPT_NAME echo ' echo "MariaDB password file not found"' >> /usr/bin/$RESTORE_SCRIPT_NAME echo ' exit 495' >> /usr/bin/$RESTORE_SCRIPT_NAME echo ' fi' >> /usr/bin/$RESTORE_SCRIPT_NAME - echo ' BACKUP_MARIADB_PASSWORD=$(> /usr/bin/$RESTORE_SCRIPT_NAME + echo ' BACKUP_MARIADB_PASSWORD=$(> /usr/bin/$RESTORE_SCRIPT_NAME echo ' echo "Restore the MariaDB user table"' >> /usr/bin/$RESTORE_SCRIPT_NAME - echo ' mysql -u root --password=$DATABASE_PASSWORD mysql -o < /root/tempmariadb/usb/backup/mariadb/mysql.sql' >> /usr/bin/$RESTORE_SCRIPT_NAME - echo ' shred -zu /root/tempmariadb/usb/backup/mariadb/db' >> /usr/bin/$RESTORE_SCRIPT_NAME + echo ' mysql -u root --password=$DATABASE_PASSWORD mysql -o < /root/tempmariadb/usb/backup/mariadb/tempmariadb/mysql.sql' >> /usr/bin/$RESTORE_SCRIPT_NAME + echo ' shred -zu /root/tempmariadb/usb/backup/mariadb/tempmariadb/db' >> /usr/bin/$RESTORE_SCRIPT_NAME echo ' rm -rf /root/tempmariadb' >> /usr/bin/$RESTORE_SCRIPT_NAME echo ' echo "Apply the new MariaDB user table"' >> /usr/bin/$RESTORE_SCRIPT_NAME echo ' mysql -u root --password=$DATABASE_PASSWORD "flush privileges;"' >> /usr/bin/$RESTORE_SCRIPT_NAME