Skip to content

Commit

Permalink
Merge pull request #491 from clschnei/add-region-env-default
Browse files Browse the repository at this point in the history
Add AWS_REGION to environment defaults
  • Loading branch information
dherault committed Sep 27, 2018
2 parents 6c94d26 + eccd315 commit 990994e
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/index.js
Expand Up @@ -550,7 +550,12 @@ class Offline {
process.env = _.extend({}, baseEnvironment);
}
else {
Object.assign(process.env, this.service.provider.environment, this.service.functions[key].environment);
Object.assign(
process.env,
{ AWS_REGION: this.service.provider.region },
this.service.provider.environment,
this.service.functions[key].environment
);
}
process.env._HANDLER = fun.handler;
handler = functionHelper.createHandler(funOptions, this.options);
Expand Down

0 comments on commit 990994e

Please sign in to comment.