summaryrefslogtreecommitdiffstats
path: root/backup.sh
diff options
context:
space:
mode:
authorKevin Hilman <khilman@baylibre.com>2020-09-04 16:09:05 -0700
committerGitHub <noreply@github.com>2020-09-04 16:09:05 -0700
commitea5ae2e3cc03560683b019d9bcf78657dec35138 (patch)
tree2fb0d01b5a5ace52d1a180c94284842880de5548 /backup.sh
parent9b1a827ac2eecb9f251881f2092305baace99c45 (diff)
parent0b86dcfa7ca3bc1342d1379a29a91f30f861fee2 (diff)
Merge pull request #127 from montjoie/misc-09-2020
Misc 09 2020
Diffstat (limited to 'backup.sh')
-rwxr-xr-xbackup.sh12
1 files changed, 6 insertions, 6 deletions
diff --git a/backup.sh b/backup.sh
index 3edd133..2f5f748 100755
--- a/backup.sh
+++ b/backup.sh
@@ -15,19 +15,19 @@ if [ -z "$DOCKERID" ];then
exit 1
fi
-docker exec -t $DOCKERID tar czf /root/devices.tar.gz /etc/lava-server/dispatcher-config/devices/ || exit $?
+docker exec $DOCKERID tar czf /root/devices.tar.gz /etc/lava-server/dispatcher-config/devices/ || exit $?
docker cp $DOCKERID:/root/devices.tar.gz $BACKUP_DIR/ || exit $?
# for an unknown reason pg_dump > file doesnt work
-docker exec -t $DOCKERID sudo -u postgres pg_dump --create --clean lavaserver --file /tmp/db_lavaserver || exit $?
-docker exec -t $DOCKERID gzip /tmp/db_lavaserver || exit $?
+docker exec $DOCKERID sudo -u postgres pg_dump --create --clean lavaserver --file /tmp/db_lavaserver || exit $?
+docker exec $DOCKERID gzip /tmp/db_lavaserver || exit $?
docker cp $DOCKERID:/tmp/db_lavaserver.gz $BACKUP_DIR/ || exit $?
-docker exec -t $DOCKERID rm /tmp/db_lavaserver.gz || exit $?
+docker exec $DOCKERID rm /tmp/db_lavaserver.gz || exit $?
# tar outputs warnings when file changes on disk while creating tar file. So do not "exit on error"
-docker exec -t $DOCKERID tar czf /root/joboutput.tar.gz /var/lib/lava-server/default/media/job-output/ || echo "WARNING: tar operation returned $?"
+docker exec $DOCKERID tar czf /root/joboutput.tar.gz /var/lib/lava-server/default/media/job-output/ || echo "WARNING: tar operation returned $?"
docker cp $DOCKERID:/root/joboutput.tar.gz $BACKUP_DIR/ || exit $?
-docker exec -t $DOCKERID rm /root/joboutput.tar.gz || exit $?
+docker exec $DOCKERID rm /root/joboutput.tar.gz || exit $?
echo "Backup done in $BACKUP_DIR"
rm -f backup-latest