Kloadut/dokku-md-plugin

Copying Databases - feature request

Closed this issue · 2 comments

When moving databases from server to server I like to pipe them over ssh i.e.

ssh -C {ssh.user}@{remote_host} mysqldump -u {remote_dbuser} --password={remote_dbpassword} {remote_dbname} | mysql -u {local_dbuser} --password={local_dbpassword} -D {local_dbname}

It would be really cool if I could pipe from the mariadb command - i.e.

ssh -C dokku@SERVER1 mariadb:dump db1 | ssh -C dokku@SERVER2 mariadb:console db1 

I've done a quick fork of this with a dump raw command - seems to be working well

ssh -C dokku@SERVER1 mariadb:dumpraw db1 | ssh -C dokku@SERVER2 mariadb:console db1

My pull request was merged a while ago so I'll close this.