How do I upload my .sql file so I can import it?
wootwoot1234 opened this issue · 4 comments
wootwoot1234 commented
I did a search and didn't' find any examples of how to migrate from another mysql database on a different server.
How do I get my upload my .sql file and reference it with the import command?
Thansk!
josegonzalez commented
I don't know how you upload files to your server - sftp or scp should work.
As far as using the import command, try the following:
dokku mysql:help import
wootwoot1234 commented
I'll check it out.
Will it only import dump files or will it accept .sql?
wootwoot1234 commented
For others that come across this same issue. I found this:
dokku mysql:create db_name
dokku mysql:link db_name app_name
sftp root@ipmydroplet
put localdirectory/filename
dokku mysql:import db_name < filename
josegonzalez commented
It just calls the mysql
bin in the container and pipes the file into it.