Restoring cryptpad with duplicity style directory
This commit is contained in:
parent
99d7f7baa6
commit
4890393e4c
|
@ -123,11 +123,17 @@ function restore_local_cryptpad {
|
||||||
function_check restore_directory_from_usb
|
function_check restore_directory_from_usb
|
||||||
restore_directory_from_usb $temp_restore_dir cryptpad
|
restore_directory_from_usb $temp_restore_dir cryptpad
|
||||||
if [ ! -d $temp_restore_dir$CRYPTPAD_DIR/datastore ]; then
|
if [ ! -d $temp_restore_dir$CRYPTPAD_DIR/datastore ]; then
|
||||||
|
if [ -d $temp_restore_dir$CRYPTPAD_DIR ]; then
|
||||||
|
cp -r $temp_restore_dir$CRYPTPAD_DIR/* $CRYPTPAD_DIR/datastore/
|
||||||
|
else
|
||||||
systemctl start cryptpad
|
systemctl start cryptpad
|
||||||
echo 'Failed to restore cryptpad'
|
echo 'Failed to restore cryptpad'
|
||||||
rm -rf $temp_restore_dir
|
rm -rf $temp_restore_dir
|
||||||
|
exit 8736529
|
||||||
fi
|
fi
|
||||||
|
else
|
||||||
cp -r $temp_restore_dir$CRYPTPAD_DIR/datastore/* $CRYPTPAD_DIR/datastore/
|
cp -r $temp_restore_dir$CRYPTPAD_DIR/datastore/* $CRYPTPAD_DIR/datastore/
|
||||||
|
fi
|
||||||
rm -rf $temp_restore_dir
|
rm -rf $temp_restore_dir
|
||||||
systemctl start cryptpad
|
systemctl start cryptpad
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in New Issue