Skip to content

Commit

Permalink
Merge branch 'meteor-mongo' into linker
Browse files Browse the repository at this point in the history
  • Loading branch information
Emily Stark committed Jun 14, 2013
2 parents 9bafe2f + 985cea3 commit ea48bf8
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 1 deletion.
8 changes: 8 additions & 0 deletions tools/deploy-galaxy.js
Original file line number Diff line number Diff line change
Expand Up @@ -228,3 +228,11 @@ exports.logs = function (options) {
logReader.close();
}
};

// options:
// - context
// - app
exports.tempMongoUrl = function (options) {
var galaxy = getGalaxy(options.context);
return galaxy.call('getTempMongoUrl', options.app);
};
14 changes: 13 additions & 1 deletion tools/meteor.js
Original file line number Diff line number Diff line change
Expand Up @@ -790,7 +790,19 @@ Fiber(function () {

} else if (new_argv._.length === 2) {
// remote mode
deploy.mongo(new_argv._[1], new_argv.url);
if (!!context.galaxyUrl) {
var deployGalaxy = require('./deploy-galaxy.js');
var url = deployGalaxy.tempMongoUrl({
app: new_argv._[1],
context: context
});
if (new_argv.url)
process.stdout.write(url + "\n");
else
deploy.run_mongo_shell(url);
} else {
deploy.mongo(new_argv._[1], new_argv.url);
}

} else {
// usage
Expand Down

0 comments on commit ea48bf8

Please sign in to comment.