amplify-education / serverless-vpc-discovery

Serverless plugin for discovering VPC / Subnet / Security Group configuration by name.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

VPC discovery errors after upgrading to 5.0.0

umulmrum opened this issue · comments

Hi,

first of all, thank you for your work on this lib!

In my team we encountered a problem with VPC discovery after upgrading from 4.1.0 to 5.0.0, which led to lambdas no longer being able to access our database in the production system.

The following messages were displayed during serverless deploy:

Function 'MyLambda' VPC not configured based on the error: UnauthorizedOperation: You are not authorized to perform this operation. User: arn:aws:sts::[] is not authorized to perform: ec2:DescribeVpcs because no identity-based policy allows the ec2:DescribeVpcs action

Unfortunately the deployment kept on running, leading to a non-functional state on AWS. So another suggestion/plea is to fail in case an error occurs, so that running applications are not affected.

Thank you for your support. Let me know if I can provide further details.

Hi @umulmrum

Could you please try the 5.0.1 version and let us know if is it fixed or not for you?

@rddimon I'm afraid the same error still occurs.

Thanks for your efforts though :-)

Does it work for you with the 4.x versions?
How are the AWS credentials configured?

From the message error User: arn:aws:sts::[] is not authorized to perform: ec2:DescribeVpcs it could be 2 problems:

  1. Plugin credentials are not set properly
  2. Your AWS credentials are not allowing DescribeVpcs

Place make sure the AWS policy is configured properly for the plugin.

Got the same Error, did not change anything in my AWS credentials file. After downgrading to for example: 3.1.2 error immediately disappeared.

Hi @umulmrum @jvollmuller-risk

Could you please try 5.0.2 and let us know if the issue is fixed for you?

@rddimon Works, thank you! 🎉