-
-
Save codemation/1529d44ef7b73cb4c458bf5bb281f107 to your computer and use it in GitHub Desktop.
Revisions
-
codemation revised this gist
Jan 17, 2021 . 1 changed file with 1 addition and 2 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -5,5 +5,4 @@ docker exec CONTAINER /usr/bin/mysqldump -u root --password=root DATABASE > back cat backup.sql | docker exec -i CONTAINER /usr/bin/mysql -u root --password=root DATABASE # Restore into Kubernetes cat backup.sql | kubectl exec -n <destination_namespace> -i <destination_pod> -- mysql -u root --password='password' <destination_database> -
codemation revised this gist
Jan 17, 2021 . 1 changed file with 3 additions and 0 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -4,3 +4,6 @@ docker exec CONTAINER /usr/bin/mysqldump -u root --password=root DATABASE > back # Restore cat backup.sql | docker exec -i CONTAINER /usr/bin/mysql -u root --password=root DATABASE # Restore into Kubernetes kubectl -n namespace exec -i my_sql_pod_name -- mysql -u user -ppassword < backup.sql -
Santiago Palladino created this gist
Dec 22, 2015 .There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,6 @@ # Backup docker exec CONTAINER /usr/bin/mysqldump -u root --password=root DATABASE > backup.sql # Restore cat backup.sql | docker exec -i CONTAINER /usr/bin/mysql -u root --password=root DATABASE