Restore directories
This commit is contained in:
parent
4cba38583b
commit
287ce6de7a
|
@ -973,16 +973,16 @@ function create_restore_script {
|
||||||
echo ' mkdir /root/tempgnusocialdata' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' mkdir /root/tempgnusocialdata' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' fi' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' fi' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo " rsyncrypto -v -d -r $USB_MOUNT/backup/gnusocialdata /root/tempgnusocialdata $USB_MOUNT/backup/gnusocialdata.keys $BACKUP_CERTIFICATE" >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo " rsyncrypto -v -d -r $USB_MOUNT/backup/gnusocialdata /root/tempgnusocialdata $USB_MOUNT/backup/gnusocialdata.keys $BACKUP_CERTIFICATE" >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' if [ ! -f /root/tempgnusocialdata/gnusocial.sql ]; then' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' if [ ! -f /root/tempgnusocialdata/usb/backup/gnusocialdata/tempgnusocialdata/gnusocial.sql ]; then' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' echo "Unable to restore microblog database"' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' echo "Unable to restore microblog database"' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' rm -rf /root/tempgnusocialdata' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' rm -rf /root/tempgnusocialdata' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo " umount $USB_MOUNT" >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo " umount $USB_MOUNT" >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo " rm -rf $USB_MOUNT" >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo " rm -rf $USB_MOUNT" >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' exit 503' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' exit 503' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' fi' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' fi' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' mysql -u root --password=$DATABASE_PASSWORD gnusocial -o < /root/tempgnusocialdata/gnusocial.sql' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' mysql -u root --password=$DATABASE_PASSWORD gnusocial -o < /root/tempgnusocialdata/usb/backup/gnusocialdata/tempgnusocialdata/gnusocial.sql' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' shred -zu /root/tempgnusocialdata/*' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' shred -zu /root/tempgnusocialdata/usb/backup/gnusocialdata/tempgnusocialdata/*' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' rm -rf /root/tempgnusocialdata' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' rm -rf /root/tempgnusocialdata/usb/backup/gnusocialdata/tempgnusocialdata' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' echo "Restoring microblog installation"' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' echo "Restoring microblog installation"' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo " rsyncrypto -v -d -r $USB_MOUNT/backup/gnusocial /var/www/$MICROBLOG_DOMAIN_NAME/htdocs $USB_MOUNT/backup/gnusocial.keys $BACKUP_CERTIFICATE" >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo " rsyncrypto -v -d -r $USB_MOUNT/backup/gnusocial /var/www/$MICROBLOG_DOMAIN_NAME/htdocs $USB_MOUNT/backup/gnusocial.keys $BACKUP_CERTIFICATE" >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo 'fi' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo 'fi' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
|
@ -996,15 +996,15 @@ function create_restore_script {
|
||||||
echo ' mkdir /root/tempredmatrixdata' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' mkdir /root/tempredmatrixdata' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' fi' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' fi' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo " rsyncrypto -v -d -r $USB_MOUNT/backup/redmatrixdata /root/tempredmatrixdata $USB_MOUNT/backup/redmatrixdata.keys $BACKUP_CERTIFICATE" >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo " rsyncrypto -v -d -r $USB_MOUNT/backup/redmatrixdata /root/tempredmatrixdata $USB_MOUNT/backup/redmatrixdata.keys $BACKUP_CERTIFICATE" >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' if [ ! -f /root/tempredmatrixdata/redmatrix.sql ]; then' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' if [ ! -f /root/tempredmatrixdata/usb/backup/redmatrixdata/tempredmatrixdata/redmatrix.sql ]; then' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' echo "Unable to restore Red Matrix database"' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' echo "Unable to restore Red Matrix database"' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' rm -rf /root/tempredmatrixdata' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' rm -rf /root/tempredmatrixdata' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo " umount $USB_MOUNT" >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo " umount $USB_MOUNT" >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo " rm -rf $USB_MOUNT" >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo " rm -rf $USB_MOUNT" >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' exit 504' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' exit 504' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' fi' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' fi' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' mysql -u root --password=$DATABASE_PASSWORD redmatrix -o < /root/tempredmatrixdata/redmatrix.sql' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' mysql -u root --password=$DATABASE_PASSWORD redmatrix -o < /root/tempredmatrixdata/usb/backup/redmatrixdata/tempredmatrixdata/redmatrix.sql' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' shred -zu /root/tempredmatrixdata/*' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' shred -zu /root/tempredmatrixdata/usb/backup/redmatrixdata/tempredmatrixdata/*' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' rm -rf /root/tempredmatrixdata' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' rm -rf /root/tempredmatrixdata' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' echo "Restoring Red Matrix installation"' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' echo "Restoring Red Matrix installation"' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo " rsyncrypto -v -d -r $USB_MOUNT/backup/redmatrix /var/www/$REDMATRIX_DOMAIN_NAME/htdocs $USB_MOUNT/backup/redmatrix.keys $BACKUP_CERTIFICATE" >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo " rsyncrypto -v -d -r $USB_MOUNT/backup/redmatrix /var/www/$REDMATRIX_DOMAIN_NAME/htdocs $USB_MOUNT/backup/redmatrix.keys $BACKUP_CERTIFICATE" >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
|
@ -1019,14 +1019,14 @@ function create_restore_script {
|
||||||
echo ' mkdir /root/tempownclouddata' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' mkdir /root/tempownclouddata' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' fi' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' fi' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo " rsyncrypto -v -d -r $USB_MOUNT/backup/ownclouddata /root/tempownclouddata $USB_MOUNT/backup/ownclouddata.keys $BACKUP_CERTIFICATE" >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo " rsyncrypto -v -d -r $USB_MOUNT/backup/ownclouddata /root/tempownclouddata $USB_MOUNT/backup/ownclouddata.keys $BACKUP_CERTIFICATE" >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' if [ ! -f /root/tempownclouddata/owncloud.sql ]; then' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' if [ ! -f /root/tempownclouddata/usb/backup/ownclouddata/tempownclouddata/owncloud.sql ]; then' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' echo "Unable to restore Owncloud database"' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' echo "Unable to restore Owncloud database"' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' rm -rf /root/tempownclouddata' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' rm -rf /root/tempownclouddata' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo " umount $USB_MOUNT" >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo " umount $USB_MOUNT" >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo " rm -rf $USB_MOUNT" >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo " rm -rf $USB_MOUNT" >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' exit 505' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' exit 505' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' fi' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' fi' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' mysql -u root --password=$DATABASE_PASSWORD owncloud -o < /root/tempownclouddata/owncloud.sql' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' mysql -u root --password=$DATABASE_PASSWORD owncloud -o < /root/tempownclouddata/usb/backup/ownclouddata/tempownclouddata/owncloud.sql' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' echo "Restoring Owncloud installation"' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' echo "Restoring Owncloud installation"' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo " rsyncrypto -v -d -r $USB_MOUNT/backup/owncloud /var/www/$OWNCLOUD_DOMAIN_NAME/htdocs $USB_MOUNT/backup/owncloud.keys $BACKUP_CERTIFICATE" >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo " rsyncrypto -v -d -r $USB_MOUNT/backup/owncloud /var/www/$OWNCLOUD_DOMAIN_NAME/htdocs $USB_MOUNT/backup/owncloud.keys $BACKUP_CERTIFICATE" >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
echo ' rm -rf /root/tempownclouddata' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
echo ' rm -rf /root/tempownclouddata' >> /usr/bin/$RESTORE_SCRIPT_NAME
|
||||||
|
|
Loading…
Reference in New Issue