[Solved] Deploy to Galaxy Failed MONGO_URL must be set in environment


#1

I create settings.json on root dir, looks like this

{
galaxy.meteor.com”: {
“env”: {
“ROOT_URL”: “http://war_game.meteorapp.com/”,
“DEPLOY_HOSTNAME”: “galaxy.meteor.com”,
“MONGO_URL”: “mongodb://user:password@ds121495.mlab.com:21495/test-data”
}
}
}

and I use this command to upload my app

meteor deploy ap-southeast-2.galaxy.meteor.com --setting settings.json

After uploading, I check the Galaxy, it’s keep showing

q29bs
2017-10-16 01:36:37+08:00/app/bundle/programs/server/node_modules/fibers/future.js:280
q29bs
2017-10-16 01:36:37+08:00 throw(ex);
q29bs
2017-10-16 01:36:37+08:00 ^
q29bs
2017-10-16 01:36:37+08:00
q29bs
2017-10-16 01:36:37+08:00Error: MONGO_URL must be set in environment
q29bs
2017-10-16 01:36:37+08:00 at Object. (packages/mongo/remote_collection_driver.js:36:11)
q29bs
2017-10-16 01:36:37+08:00 at Object.defaultRemoteCollectionDriver (packages/underscore.js:784:19)
q29bs
2017-10-16 01:36:37+08:00 at new Mongo.Collection (packages/mongo/collection.js:99:40)
q29bs
2017-10-16 01:36:37+08:00 at AccountsServer.AccountsCommon (packages/accounts-base/accounts_common.js:23:18)
q29bs
2017-10-16 01:36:37+08:00 at new AccountsServer (packages/accounts-base/accounts_server.js:18:5)
q29bs
2017-10-16 01:36:37+08:00 at meteorInstall.node_modules.meteor.accounts-base.server_main.js (packages/accounts-base/server_main.js:9:12)
q29bs
2017-10-16 01:36:37+08:00 at fileEvaluate (packages/modules-runtime.js:333:9)
q29bs
2017-10-16 01:36:37+08:00 at require (packages/modules-runtime.js:228:16)
q29bs
2017-10-16 01:36:37+08:00 at /app/bundle/programs/server/packages/accounts-base.js:2048:15
q29bs
2017-10-16 01:36:37+08:00 at /app/bundle/programs/server/packages/accounts-base.js:2059:3

it’s really drive me crazy…any solution?


#2

--settings not --setting


#3

OMG it works…

After I deploy, where is the link to my app? I only use Heroku before…


#4

If you click the app from your list of apps on galaxy, you should see the URL in the header. It’s hard to miss.


#5

Thank you, I just mess around :frowning: