Module library

Route 53

Terraform module to create AWS Route53 resources

Version
Submodules
delegation-setsresolver-endpointresolver-firewall-rule-group

Inputs

22
commentoptionalstring

A comment for the hosted zone. Defaults to `Managed by Terraform`

Defaultnull
createoptionalbool

Whether to create Route53 zone

Defaulttrue
create_dnssec_kms_keyoptionalbool

Whether to create a KMS key for DNSSEC signing

Defaulttrue
create_zoneoptionalbool

Determines whether to create the Route53 zone or lookup an existing zone

Defaulttrue
delegation_set_idoptionalstring

The ID of the reusable delegation set whose NS records you want to assign to the hosted zone. Conflicts with vpc as delegation sets can only be used for public zones

Defaultnull
dnssec_key_signing_key_nameoptionalstring

Name of the Route 53 key signing key (KSK). When null, the hosted zone name is used. Set this to match an existing KSK when importing or adopting DNSSEC without recreating the key

Defaultnull
dnssec_kms_key_aliasesoptionallist(string)

A list of aliases to create. Note - due to the use of `toset()`, values must be static strings and not computed values

Default[]
dnssec_kms_key_arnoptionalstring

The ARN of the KMS key to use for DNSSEC signing. Required when `create_dnssec_kms_key` is `false`

Defaultnull
dnssec_kms_key_descriptionoptionalstring

The description of the key as viewed in AWS console

DefaultRoute53 DNSSEC KMS Key
dnssec_kms_key_tagsoptionalmap(string)

Additional tags to apply to the KMS key created for DNSSEC signing

Default{}
enable_accelerated_recoveryoptionalbool

Whether to enable Route 53 Accelerated Recovery for the public hosted zone. When enabled, provides a 60-minute RTO for resuming DNS record management if the US East (N. Virginia) Region becomes unavailable. Only applies to public hosted zones

Defaultnull
enable_dnssecoptionalbool

Whether to enable DNSSEC for the Route53 zone

Defaultfalse
force_destroyoptionalbool

Whether to destroy all records (possibly managed outside of Terraform) in the zone when destroying the zone

Defaultnull
ignore_vpcoptionalbool

Determines whether to ignore VPC association changes after creation to avoid disruptive diffs when using `aws_route53_zone_association` resource(s). Changing is a destructive action; users should be prepared to use Terraform state move commands/blocks when changing this value

Defaultfalse
nameoptionalstring

This is the name of the hosted zone

Default""
private_zoneoptionalbool

Whether the hosted zone is private. Only applicable when `create_zone = false`

Defaultfalse
recordsoptionalmap(object({ alias = optional(object({ evaluate_target_health = optional(bool, f…

A map of Route53 records to create in the zone. The key can be used as the subdomain name, or `name` can be used to specify the full name

Default{}
tagsoptionalmap(string)

Tags added to all zones. Will take precedence over tags from the 'zones' variable

Default{}
timeoutsoptionalobject({ create = optional(string) update = optional(string) delete = optional(s…

Timeouts for the Route53 zone operations

Defaultnull
vpcoptionalmap(object({ vpc_id = string vpc_region = optional(string) }))

Configuration block(s) specifying VPC(s) to associate with a private hosted zone. Conflicts with the delegation_set_id argument in this resource and any aws_route53_zone_association resource specifying the same zone ID

Defaultnull
vpc_association_authorizationsoptionalmap(object({ vpc_id = string vpc_region = optional(string) }))

A map of VPC association authorizations to create for the Route53 zone

Defaultnull
vpc_idoptionalstring

The ID of the VPC associated with the existing hosted zone. Only applicable when `create_zone = false`

Defaultnull

All 22 are optional — the module deploys with none of them set.

Outputs

16
arn

Zone ARN of Route53 zone

dnssec_kms_key_arn

The Amazon Resource Name (ARN) of the key

dnssec_kms_key_id

The globally unique identifier for the key

dnssec_kms_key_policy

The IAM resource policy set on the key

dnssec_kms_key_region

The region for the key

dnssec_signing_key_digest_value

A cryptographic digest of a DNSKEY resource record (RR). DNSKEY records are used to publish the public key that resolvers can use to verify DNSSEC signatures that are used to secure certain kinds of information provided by the DNS system

dnssec_signing_key_dnskey_record

A string that represents a DNSKEY record

dnssec_signing_key_ds_record

A string that represents a delegation signer (DS) record

dnssec_signing_key_id

Route 53 Hosted Zone identifier and KMS Key identifier, separated by a comma (`,`)

dnssec_signing_key_public_key

The public key, represented as a Base64 encoding, as required by RFC-4034 Page 5

dnssec_signing_key_tag

An integer used to identify the DNSSEC record for the domain name. The process used to calculate the value is described in RFC-4034 Appendix B

id

Zone ID of Route53 zone

name

Name of Route53 zone

name_servers

Name servers of Route53 zone

primary_name_server

The Route 53 name server that created the SOA record.

records

Records created in the Route53 zone

What the agent wires into the next module. An edge on the architecture diagram is one of these consumed by something else.