1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/restic_ynh.git synced 2024-09-03 20:16:22 +02:00

feat: check repository after backup

This commit is contained in:
Lionel Coupouchetty-Ramouchetty 2020-02-25 18:39:13 +01:00
parent df73c9177a
commit 11104e1af9
2 changed files with 3 additions and 1 deletions

View file

@ -51,6 +51,8 @@ Sat *-*-1..7 18:00:00 : The first saturday of every month at 18:00
After each invocation an e-mail will be sent to root@yourdomain.tld with the execution log. After each invocation an e-mail will be sent to root@yourdomain.tld with the execution log.
NOTE: After each backup, the repository integrity is checked
See here for more info : https://wiki.archlinux.org/index.php/Systemd/Timers#Realtime_timer See here for more info : https://wiki.archlinux.org/index.php/Systemd/Timers#Realtime_timer
At the end of the installation, the app displays the public_key and the user to give to the person who has access to the server B. At the end of the installation, the app displays the public_key and the user to give to the person who has access to the server B.
@ -115,5 +117,4 @@ You can setup the restic app several times on the same server so you can backup
## TODO ## TODO
* Schedule backup check
* Remove expect message when question was not matched * Remove expect message when question was not matched

View file

@ -34,6 +34,7 @@ do_backup() {
pushd $work_dir pushd $work_dir
$RESTIC_COMMAND backup ./ >> $LOGFILE 2>> $ERRFILE $RESTIC_COMMAND backup ./ >> $LOGFILE 2>> $ERRFILE
return_code="$?" return_code="$?"
$RESTIC_COMMAND check >> $LOGFILE 2>> $ERRFILE
popd popd
# On ne nettoie que si la sauvegarde s'est bien passee # On ne nettoie que si la sauvegarde s'est bien passee