brianz / serverless-design-patterns

Repository for Serverless Design Patterns and Best Practices book
MIT License
40 stars 13 forks source link

Error when deploying--invalid subnets #16

Open mlfarrelly opened 5 years ago

mlfarrelly commented 5 years ago

Really enjoying the book, but when I try to deploy, I keep getting this error message:

Error message:

An error occurred: RDSSubnetGroup - Some input subnets in :[subnet-04cb33f4001924f59, subnet-084fb5fd9987a0cf7] are invalid. (Service: AmazonRDS; Status Code: 400; Error Code: InvalidParameterValue; Request ID: 60ac3262-5b4c-43b8-b924-7043d6299e62).

I've tried manually creating new VPCs and subnets per the AWS docs, but nothing is working for me.

Any thoughts? Thanks!

brianz commented 5 years ago

Hi @mwebdev1

Thanks for this, I'll take a look. Which chapter's code were you seeing this error?

mlfarrelly commented 5 years ago

Thanks for this, I'll take a look. Which chapter's code were you seeing this error?

Chapter 2. I'm getting the error when I try to deploy with a yml file based off of yours:

`functions: createuser: handler: api/handlers.createuser events:

plugins:

resources: Resources: ServerlessSecurityGroup: Type: AWS::EC2::SecurityGroup Properties: GroupDescription: SecurityGroup for Serverless Functions VpcId: ${file(./config/config.${self:provider.stage}.json):VPC_ID} RDSSecurityGroup: Type: AWS::EC2::SecurityGroup Properties: GroupDescription: Ingress for RDS Instance VpcId: ${file(./config/config.${self:provider.stage}.json):VPC_ID} SecurityGroupIngress:

Thanks!