aboutsummaryrefslogtreecommitdiff
path: root/src/infrastructure/scripts
diff options
context:
space:
mode:
authorEuAndreh <eu@euandre.org>2023-03-30 08:35:16 -0300
committerEuAndreh <eu@euandre.org>2023-03-30 08:35:16 -0300
commitbe84eba41f29df406d5bedc6a7228840c89f4e9f (patch)
treea8c5df408a6b620748ecc183cbd9b3f3006b2bd7 /src/infrastructure/scripts
parentconf.env: Separate $RSYNC_ACCT from $RSYNC_ADDR (diff)
downloadtoph-be84eba41f29df406d5bedc6a7228840c89f4e9f.tar.gz
toph-be84eba41f29df406d5bedc6a7228840c89f4e9f.tar.xz
backup.sh: Fix capture of $STATUS to the desired behaviour
Notes
See CI logs with: git notes --ref=refs/notes/ci-logs show be84eba41f29df406d5bedc6a7228840c89f4e9f git notes --ref=refs/notes/ci-data show be84eba41f29df406d5bedc6a7228840c89f4e9f Exit status: 0 Duration: 22
Diffstat (limited to 'src/infrastructure/scripts')
-rwxr-xr-xsrc/infrastructure/scripts/backup.sh4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/infrastructure/scripts/backup.sh b/src/infrastructure/scripts/backup.sh
index 47cc76c..83a6cdc 100755
--- a/src/infrastructure/scripts/backup.sh
+++ b/src/infrastructure/scripts/backup.sh
@@ -102,6 +102,7 @@ fi
run() {
+ STATUS=0
set -x
# shellcheck disable=2086
sudo -i borg create \
@@ -116,8 +117,7 @@ run() {
/etc/ \
/var/ \
/opt/ \
- /srv/
- STATUS=$?
+ /srv/ || STATUS=$?
set +x
if [ "$STATUS" = 0 ]; then