dokku / dokku-mongo

a mongo plugin for dokku
MIT License
177 stars 32 forks source link

Ability to --drop DB and do a full import #32

Closed newbreedofgeek closed 9 years ago

newbreedofgeek commented 9 years ago

Hello,

Not sure if this is an issue or just not documented.

I need to be able to do something like this: dokku mongo:import current-db < new-db.tar --drop

i.e. I'd like to import new-db.tar and drop current-db before the import happens.

Currently when I do: dokku mongo:import current-db < new-db.tar

The DBs are "merged" which is not what you want in certain occasions.

In MongoDB world you can do this via, which is ideally what I'm after: mongorestore --db current-db --drop new-db.tar

Thanks, Mark.

josegonzalez commented 9 years ago

Can you just use the mongocli to drop the database manually and then run the import?

josegonzalez commented 9 years ago

@newbreedofgeek bump

josegonzalez commented 9 years ago

Closing as there hasn't been any response.