1 Antwort
- Neueste
- Die meisten Stimmen
- Die meisten Kommentare
0
Hi,
A subnet is called a Public subnet if it has a direct route to an internet gateway. Resources in a public subnet can access the public internet. To read more about Subnets in VPC https://docs.aws.amazon.com/vpc/latest/userguide/configure-subnets.html
If the subnet has a route to anywhere through Internet gateway. It's a Public subnet. Here is how the route table will look like https://docs.aws.amazon.com/vpc/latest/userguide/route-table-options.html#route-tables-internet-gateway
To resolve your issue:
- VPC Configuration: Check if your VPC has the necessary subnets (public, private, etc.) created.
- Subnet Group Names: Ensure that you’re using the correct subnet group names in your configuration.
- Internet Gateway: If you’re expecting a public subnet, make sure it has an associated internet gateway.
- Route Tables: Check the route tables associated with your subnets. Public subnets should have a route to the internet gateway (0.0.0.0/0).
Additionally, you can refer here: https://stackoverflow.com/questions/56980500/aws-cdk-error-there-are-no-public-subnets-in-this-vpc-use-a-different-vpc-su
tag: Key: aws-cdk:subnet-type Value: Public
Relevanter Inhalt
- AWS OFFICIALAktualisiert vor 3 Jahren
- AWS OFFICIALAktualisiert vor einem Jahr