Skip to content

Commit b225815

Browse files
authored
Merge pull request #82 from apigee-internal/remove-keys-from-args
Updates to remove keys from process args.
2 parents bde474e + c54c158 commit b225815

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

cli/lib/gateway.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@ Gateway.prototype.start = (options) => {
6161
}
6262

6363
var opt = {};
64+
delete args.keys;
6465
opt.args = [JSON.stringify(args)];
6566
opt.timeout = 10;
6667

lib/agent-config.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,8 @@ const getConfigStart = function getConfigStart(options, cb) {
2020
fs.exists(options.target, (exists) => {
2121
if (exists) {
2222
const config = edgeConfig.load({ source: options.target });
23-
startServer(options.keys, options.pluginDir,config, cb);
23+
const keys = {key: config.analytics.key, secret: config.analytics.secret};
24+
startServer(keys, options.pluginDir,config, cb);
2425
} else {
2526
return cb(options.target+" must exist")
2627
}
@@ -32,4 +33,4 @@ const startServer = function startServer(keys, pluginDir,config, cb) {
3233
agent.start(keys, pluginDir, config, function (err) {
3334
cb(err, agent, config);
3435
});
35-
}
36+
}

0 commit comments

Comments
 (0)