afloyd / mongo-migrate

MIT License
159 stars 81 forks source link

migrate on heroku (and mongoLab) #43

Closed kolodkin closed 9 years ago

kolodkin commented 9 years ago

after successfully migrating changes in db on local host , i couldn't duplicate migration on heroku where my app is deployed.

I run the script throw heroku console: heroku run "node ./node_modules/mongodb-migrate -runmm -cfg migration-config.json up"

what should be in the configuration file under host, db and port?

kolodkin commented 9 years ago

issue solved. i migrated the change from my local PC to MogoLab database using the following configuration .json

{ "mongoAppDb": { "host": host, "db": dbname, "port": port, "username": username, "password": pass } }

taking variables value from heroku MongoLAB url (using heroku config) where the url format is as follows: mongodb://user:pass@host:port/dbname

afloyd commented 9 years ago

Great work glad you were able to figure it out!

On Thu, Aug 6, 2015, 7:35 AM mark kolodkin notifications@github.com wrote:

issue solved. i migrated the change from my local PC to MogoLab database using the following configuration .json

{ "mongoAppDb": { "host": , "db": , "port": , "username": , "password": } }

taking variables value from heroku MongoLAB url (using heroku config) where the url format is as follows: mongodb://:@:/

— Reply to this email directly or view it on GitHub https://github.com/afloyd/mongo-migrate/issues/43#issuecomment-128266216 .