Created
April 25, 2020 00:11
-
-
Save raicerk/a9965be88738552f3162315f4519dfaa to your computer and use it in GitHub Desktop.
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
//Ejecutar respaldo | |
docker exec -t your-db-container pg_dumpall -c -U postgres > dump_`date +%d-%m-%Y"_"%H_%M_%S`.sql | |
//Ejecutar restauracion | |
cat your_dump.sql | docker exec -i your-db-container psql -U postgres -d nombredb | |
//-U corresponde al usuario de la base de datos |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment