Created
December 4, 2012 21:43
-
-
Save adrienjoly/4209082 to your computer and use it in GitHub Desktop.
dump a dotcloud-hosted mongodb database and retrieve it locally, on mac os
This file contains 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
dotcloud run db "mongodump -h APPNAME.dotcloud.com:DBPORT -u root -p PASSWORD -d DBNAME" | |
dotcloud run db -- \ | |
"tar -chf- dump 2>/dev/null | base64 -w0" \ | |
| base64 -d > backup-`date +%s`.tar |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment