aboutsummaryrefslogtreecommitdiff
path: root/jobs
diff options
context:
space:
mode:
authorMasaya Tojo <masaya@tojo.tokyo>2021-09-14 03:58:20 +0900
committerMasaya Tojo <masaya@tojo.tokyo>2021-09-14 03:58:20 +0900
commit332646d5a62ebd6333f1f745d0b058f9137fbb54 (patch)
tree8b403c93e27785170247b5c9743d610b5e835654 /jobs
parentcf45305724b66b5b7cff5198e9001a8e0850f65a (diff)
check-backup-of-nextcloud: Update.
Diffstat (limited to 'jobs')
-rwxr-xr-xjobs/check-backup-of-nextcloud.run3
1 files changed, 1 insertions, 2 deletions
diff --git a/jobs/check-backup-of-nextcloud.run b/jobs/check-backup-of-nextcloud.run
index 75b0939..0452dbf 100755
--- a/jobs/check-backup-of-nextcloud.run
+++ b/jobs/check-backup-of-nextcloud.run
@@ -4,9 +4,8 @@ set -euo pipefail
todays_backup="s3://qkbackup/nextcloud/$(date "+%w")/"
echo "Check $todays_backup."
output="$(guix environment --ad-hoc python2-s3cmd -- s3cmd ls "$todays_backup")"
-echo "$output"
# UTC の時刻で日付が同日の場合はバックアップに成功していると見做す
echo "$output" |\
awk -v utc_today="$(TZ=UTC date "+%F")" \
- '$1 != utc_today { print "Failed!"; exit 1 }'
+ '$1 != utc_today { print "Failed!"; exit 1 } ; { print }'