Amazon Route53 Construct Library
To add a public hosted zone:
;new route53.PublicHostedZonethis, 'HostedZone',;
To add a private hosted zone, use
PrivateHostedZone. Note that
enableDnsSupport must have been enabled for the
VPC you're configuring for private hosted zones.
Additional VPCs can be added with
To add a TXT record to your zone:
;new route53.TxtRecordthis, 'TXTRecord',;
To add a A record to your zone:
;new route53.ARecordthis, 'ARecord',;
To add a AAAA record pointing to a CloudFront distribution:
;;new route53.AaaaRecordthis, 'Alias',;
Constructs are available for A, AAAA, CAA, CNAME, MX, NS, SRV and TXT records.
CaaAmazonRecord construct to easily restrict certificate authorities
allowed to issue certificates for a domain to Amazon only.
If you don't know the ID of the Hosted Zone to import, you can use the
HostedZone.fromLookup requires an environment to be configured. Check
out the documentation for more documentation and examples. CDK
automatically looks into your
~/.aws/config file for the
If you want to specify a different account run
cdk deploy --profile [profile].
new MyDevStackapp, 'dev',;
If you know the ID and Name of a Hosted Zone, you can import it directly:
Alternatively, use the
HostedZone.fromHostedZoneId to import hosted zones if
you know the ID and the retrieval for the
zoneName is undesirable.