Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Region update from serverless.yml #89

Closed
Dalfons0 opened this issue Jan 19, 2017 · 5 comments
Closed

Region update from serverless.yml #89

Dalfons0 opened this issue Jan 19, 2017 · 5 comments

Comments

@Dalfons0
Copy link

Dalfons0 commented Jan 19, 2017

I'm not sure if this is an issue but I think is a good addition. The thing is that if you try to invoke a function that access an aws service (e.g. DynamoDB), with serverless webpack invoke or serverless webpack serve and you haven't specified the region in the handler like AWS.config.region = "us-west-2" or AWS.config.update({region: "us-west-2"}), you got this error:

  Config Error -------------------------------------------

     Missing region in config

And this doesn't happen if you invoke a function with the command serverless invoke local who I suppose is getting the region from serverless.yml

@hassankhan
Copy link
Contributor

This is happening for me too, I've defined my stage and region in serverless.yml.

@hassankhan
Copy link
Contributor

I've posted my workaround for this issue here.

@Dalfons0
Copy link
Author

@hassankhan Thanks for the info!

@HyperBrain
Copy link
Member

@Dalfons0 We'll switch the invoke command to use serverless invoke local with version 3.0.0. A working PR is already available ( #153 ). Could you check if it works with that source code revision if you use serverless invoke local?

@HyperBrain
Copy link
Member

invoke will be removed in the next v3.0.0 release and integrates fully with serverless invoke local (see #151 ). No efforts will be spent on the function anymore. So I'll close this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants