Skip to content

Commit

Permalink
fix backup script again
Browse files Browse the repository at this point in the history
  • Loading branch information
JeromeBu committed Aug 7, 2024
1 parent 5f8b875 commit bab6b1d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion backup-db.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ if [ -z "$POSTGRES_USER" ]; then
exit 1
fi

docker compose -f $SCRIPT_DIR/docker-compose.prod.yml exec -it postgres pg_dump -U $POSTGRES_USER -d $POSTGRES_DB > $SCRIPT_DIR/../db-backups/dump-$(date +'%Y-%m-%dT%H:%M').sql
sudo docker compose -f $SCRIPT_DIR/docker-compose.prod.yml exec -it postgres pg_dump -U $POSTGRES_USER -d $POSTGRES_DB > $SCRIPT_DIR/../db-backups/dump-$(date +'%Y-%m-%dT%H:%M').sql

if [ $? -eq 0 ]; then
echo Success !
Expand Down

0 comments on commit bab6b1d

Please sign in to comment.