aws-cdk-examples icon indicating copy to clipboard operation
aws-cdk-examples copied to clipboard

Error for Static site

Open sagarkukrejagit opened this issue 3 years ago • 5 comments
trafficstars

Hi Team,

I am getting an error saying [Error at /MyStaticSite/StaticSite] Found zones: [] for dns:mystaticsite.com, privateZone:undefined, vpcId:undefined, but wanted exactly 1 zone Found errors while i do cdk synth

I have created a private hosted zone named mystaticsite.com in my AWS account and have linked the same in the code

Kindly look into it and guide me on the same.

Thank You.

Regards, Sagar

sagarkukrejagit avatar Feb 18 '22 07:02 sagarkukrejagit

samesies..

brian-stoker avatar Jul 27 '22 19:07 brian-stoker

same error here

PavanMudigondaTR avatar Dec 10 '22 19:12 PavanMudigondaTR

Still happening. Any hints as to how this can be fixed? Looks like route53.HostedZone.fromLookup does get the zone but it seems to be incompatible with the zone needed for route53.ARecord.

gkfirst8 avatar Apr 26 '23 11:04 gkfirst8

in my case the issue was that i was using a domain name that was incorrect.

const hostedZone = route53.HostedZone.fromLookup(this, buildConfig.Parameters.AWS_HOSTED_ZONE_ID, { domainName: buildConfig.Parameters.AWS_DOMAIN_NAME });

The domain name i had to use was something like link.something.com but i defined it as api.link.something.com

narcisghe avatar Apr 02 '24 06:04 narcisghe

To confirm this is the typescript/static-site example?

kaiz-io avatar Apr 03 '24 13:04 kaiz-io

⚠️COMMENT VISIBILITY WARNING⚠️

Comments on closed issues are hard for our team to see. If you need more assistance, please either tag a team member or open a new issue that references this one. If you wish to keep having a conversation with other community members under this issue feel free to do so.

github-actions[bot] avatar Dec 27 '24 21:12 github-actions[bot]