forked from cloudfoundry/bosh-bootloader
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add plan-patch for AWS DNS delegation
- Loading branch information
1 parent
0ae20af
commit bd2a1cd
Showing
2 changed files
with
21 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
## AWS DNS Delegation | ||
|
||
If you have a DNS parent zone, this plan-patch creates the required "NS" record for DNS delegation. Can be used if `parent_zone` is empty, see: | ||
https://github.com/cloudfoundry/bosh-bootloader/blob/2a4d71fd093a77f6895e411c56fa6c14329b9d3f/terraform/aws/templates/cf_dns.tf#L5 | ||
``` | ||
cp -r bosh-bootloader/plan-patches/dns-delegation-aws/. some-env/ | ||
bbl up | ||
``` |
13 changes: 13 additions & 0 deletions
13
plan-patches/dns-delegation-aws/terraform/aws_parent_ns.tf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
variable "parent_zone_id" { | ||
type = "string" | ||
description = "The AWS Route53 hosted zone ID for the 'parent' of the zone that bbl will create, used to set up DNS delegation" | ||
} | ||
|
||
resource "aws_route53_record" "perf-test" { | ||
name = "${var.system_domain}" | ||
ttl = 172800 | ||
type = "NS" | ||
zone_id = "${var.parent_zone_id}" | ||
|
||
records = ["${aws_route53_zone.env_dns_zone.name_servers}"] | ||
} |