sheharyarn / mongo-sync

Sync Remote and Local MongoDB Databases :fire:
https://sheharyar.me/blog/sync-mongodb-local-and-production-heroku/
319 stars 89 forks source link

AuthenticationDatabase parameter for Mongo 3.4+ #19

Closed humblepride closed 6 years ago

humblepride commented 6 years ago

like this: LOCAL_CREDENTIALS="-u $local_access_username -p $local_access_password --authenticationDatabase admin" REMOTE_CREDENTIALS="-u $remote_access_username -p $remote_access_password --authenticationDatabase admin"

sheharyarn commented 6 years ago

Thank you for opening this issue, but please see PR #20 that tries to add this feature:

The main design goal of this project is to provide a very minimal set of features to easily dump/restore mongo databases. To this end, I've deliberately not added options that don't appeal to the majority of the users. But this also allows others to extend the script according to their specific use-cases without a lot of effort, just like you did.

You can also download @j0e1in's customized version of the script that addresses this.


I haven't used MongoDB in quite a while, but if other users believe this is an extremely important feature, we might open the PR again and merge it.