Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Creates an Amazon Route 53 hosted zone
AWSTemplateFormatVersion: '2010-09-09'
Description: Creates an Amazon Route 53 hosted zone
Parameters:
DomainName:
Type: String
Description: The DNS name of an Amazon Route 53 hosted zone e.g. jevsejev.io
AllowedPattern: (?!-)[a-zA-Z0-9-.]{1,63}(?<!-)
ConstraintDescription: must be a valid DNS zone name.
Resources:
DNS:
Type: AWS::Route53::HostedZone
Properties:
HostedZoneConfig:
Comment: !Join ['', ['Hosted zone for ', !Ref 'DomainName']]
Name: !Ref 'DomainName'
HostedZoneTags:
- Key: Purpose
Value: fermi
Outputs:
fermiNS:
Description: NameServers
Value: !Join [',', !GetAtt DNS.NameServers]
Export:
Name: fermiNS
HostedZoneName:
Description: 'The fully qualified domain name'
Value: !Ref DomainName
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.