Created
October 31, 2022 23:36
-
-
Save ThinGuy/fe6745308284a58a5f69117b28af9081 to your computer and use it in GitHub Desktop.
Run pg_dumpall against maas-test-db
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
sudo -iu root psql -U postgres -h /var/snap/maas-test-db/common/postgres/sockets -d maasdb -c "ALTER ROLE maas WITH SUPERUSER" | |
sudo -iu root pg_dumpall -U maas -l maasdb -h /var/snap/maas-test-db/common/postgres/sockets -c|tee 1>/dev/null ~/dump.sql |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment