diff options
author | Patrick Spek <p.spek@tyil.nl> | 2022-05-26 21:32:43 +0200 |
---|---|---|
committer | Patrick Spek <p.spek@tyil.nl> | 2022-05-26 21:32:43 +0200 |
commit | 838ca850c488fdd9ed69c2aa2a64cf50f1fca80d (patch) | |
tree | d418d1239fb063482b93b09783c65c363dd9380f | |
parent | 36f43b055abf1b348b5ef49f03dd3d8d30792f4a (diff) |
Make borg read from stdin for pg_dump backups
-rw-r--r-- | lib/subcommands/backup.bash | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/subcommands/backup.bash b/lib/subcommands/backup.bash index 65a5d88..f454a4b 100644 --- a/lib/subcommands/backup.bash +++ b/lib/subcommands/backup.bash @@ -150,6 +150,7 @@ backup_database_postgresql() { pg_dump "$database" \ | borg create \ --remote-path "$remote" \ - "$repo/postgresql-$database::$database-$(datetime)" + "$repo/postgresql-$database::$database-$(datetime)" \ + - done < <(psql -AXt -d template1 -c "SELECT datname FROM pg_database") } |