Skip to content

Commit

Permalink
Merge pull request #4654 from ministryofjustice/doc/private-dns-docum…
Browse files Browse the repository at this point in the history
…entation

Additional changes for private VPC zone docs
  • Loading branch information
markgov authored Jul 26, 2023
2 parents fd23c82 + 2b9cd20 commit e16cb9b
Showing 1 changed file with 15 additions and 15 deletions.
30 changes: 15 additions & 15 deletions source/runbooks/creating-new-private-dns-zones.html.md.erb
Original file line number Diff line number Diff line change
Expand Up @@ -34,28 +34,28 @@ In the pull request simply add a business name and supply the DNS name for the p

To extend DNS zones amend the code in [here](https://github.com/ministryofjustice/modernisation-platform/blob/main/terraform/environments/core-vpc/vpc.tf).

If the below sections are already unhashed simply add in your business unit and DNS name to the locals section like what was done in the pr to create the DNS zone above.
local.private-application-zones should contain a mapping of business units to private Route53 hosted zones. This local is supplied to a module that configures the VPC-to-zone association.

#### Example

```terraform
# locals {
# private-application-zones = {
locals {
private-application-zones = {

# }
# }
}
}


# module "private_dns_zone_extend" {
# providers = {
# aws.core-network-services = aws.core-network-services
# aws.core-vpc = aws
# }
module "private_dns_zone_extend" {
providers = {
aws.core-network-services = aws.core-network-services
aws.core-vpc = aws
}

# for_each = local.vpcs[terraform.workspace]
# source = "../../modules/private-dns-zone-extend"
# business_unit_name = local.private-application-zones[each.key]
# vpc_id = module.vpc[each.key].vpc_id
for_each = local.vpcs[terraform.workspace]
source = "../../modules/private-dns-zone-extend"
business_unit_name = local.private-application-zones[each.key]
vpc_id = module.vpc[each.key].vpc_id

# }
}
```

0 comments on commit e16cb9b

Please sign in to comment.