Route53Configuration
Configures the Route53 record sets for an API.
Syntax
To declare this entity in your AWS Serverless Application Model (AWS SAM) template, use the following syntax.
YAML
DistributionDomainName:
String
EvaluateTargetHealth:Boolean
HostedZoneId:String
HostedZoneName:String
IpV6:Boolean
Properties
-
DistributionDomainName
-
Configures a custom distribution of the API custom domain name.
Type: String
Required: No
Default: Use the API Gateway distribution.
AWS CloudFormation compatibility: This property is passed directly to the
DNSName
property of anAWS::Route53::RecordSetGroup AliasTarget
resource.Additional notes: The domain name of a CloudFront distribution.
-
EvaluateTargetHealth
-
When EvaluateTargetHealth is true, an alias record inherits the health of the referenced AWS resource, such as an Elastic Load Balancing load balancer or another record in the hosted zone.
Type: Boolean
Required: No
AWS CloudFormation compatibility: This property is passed directly to the
EvaluateTargetHealth
property of anAWS::Route53::RecordSetGroup AliasTarget
resource.Additional notes: You can't set EvaluateTargetHealth to true when the alias target is a CloudFront distribution.
-
HostedZoneId
-
The ID of the hosted zone that you want to create records in.
Specify either
HostedZoneName
orHostedZoneId
, but not both. If you have multiple hosted zones with the same domain name, you must specify the hosted zone usingHostedZoneId
.Type: String
Required: No
AWS CloudFormation compatibility: This property is passed directly to the
HostedZoneId
property of anAWS::Route53::RecordSetGroup RecordSet
resource. -
HostedZoneName
-
The name of the hosted zone that you want to create records in.
Specify either
HostedZoneName
orHostedZoneId
, but not both. If you have multiple hosted zones with the same domain name, you must specify the hosted zone usingHostedZoneId
.Type: String
Required: No
AWS CloudFormation compatibility: This property is passed directly to the
HostedZoneName
property of anAWS::Route53::RecordSetGroup RecordSet
resource. -
IpV6
-
When this property is set, AWS SAM creates a
AWS::Route53::RecordSet
resource and sets Type toAAAA
for the provided HostedZone.Type: Boolean
Required: No
AWS CloudFormation compatibility: This property is unique to AWS SAM and doesn't have an AWS CloudFormation equivalent.
Examples
Route 53 Configuration Example
This example shows how to configure RouteĀ 53.
YAML
Domain: DomainName: www.example.com CertificateArn: arn-example EndpointConfiguration: EDGE Route53: HostedZoneId: Z1PA6795UKMFR9 EvaluateTargetHealth: true DistributionDomainName: xyz