Skip to content
Snippets Groups Projects
Commit b2d27a91 authored by Bob Mottram's avatar Bob Mottram
Browse files

backup www directory

parent a0d693cc
No related branches found
No related tags found
No related merge requests found
......@@ -97,7 +97,7 @@ function backup_local_radicale {
function_check backup_directory_to_usb
backup_directory_to_usb $source_directory $dest_directory
fi
source_directory=/var/www/radicale/collections
source_directory=/var/www/radicale
if [ -d $source_directory ]; then
dest_directory=radicalecollections
function_check backup_directory_to_usb
......@@ -120,7 +120,7 @@ function restore_local_radicale {
temp_restore_dir=/root/tempradicalecollections
restore_directory_from_usb $temp_restore_dir radicalecollections
cp -r $temp_restore_dir/var/www/radicale/collections/* /var/www/radicale/collections
cp -r $temp_restore_dir/var/www/radicale/* /var/www/radicale
if [ ! "$?" = "0" ]; then
function_check backup_unmount_drive
backup_unmount_drive
......@@ -137,7 +137,7 @@ function backup_remote_radicale {
if [ -d ${RADICALE_DIRECTORY} ]; then
echo $"Backing up the radicale settings"
backup_directory_to_friend ${RADICALE_DIRECTORY} radicale
backup_directory_to_friend /var/www/radicale/collections radicalecollections
backup_directory_to_friend /var/www/radicale radicalecollections
echo $"Backup of radicale settings complete"
fi
}
......@@ -155,7 +155,7 @@ function restore_remote_radicale {
temp_restore_dir=/root/tempradicalecollections
restore_directory_from_friend $temp_restore_dir radicalecollections
cp -r $temp_restore_dir/var/www/radicale/collections/* /var/www/radicale/collections
cp -r $temp_restore_dir/var/www/radicale/* /var/www/radicale
if [ ! "$?" = "0" ]; then
exit 3674284
fi
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment