padrino-framework
padrino-framework copied to clipboard
Creating databases without invoking binaries
Currently when you create a new Padrino project with PostreSQL adapter when you try to create or drop the database it tries to call createdb
or dropdb
binary as seen in padrino-gen/padrino-tasks/sql-helpers.rb.
While this works in general it's pretty useless when the database sits in a container (Docker for example). I know that ActiveRecord does this without relying on binaries. Would it be possible to replicate this in Padrino so we don't rely on binaries?
Pretty sure since ActiveRecord 4 the given DB's binaries are used for dumping.
With MySQL for example, triggers were not dumped until they moved to mysqldump
. Situation may have been similar for PostreSQL, but I don't use it so not sure. 😳
@sshaw For dumping? Maybe. For creating the database - definitely not since I can use Rails with Postgres in Docker OOB provided I setup the right credentials in configuration.
For dumping? Maybe. For creating the database - definitely not since
Ah yes, you're correct.