Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DSOS-2537: Add load balancer certificate for hmpps-domain-services #4548

Merged
merged 1 commit into from
Jan 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -5,21 +5,22 @@ locals {
development_config = {

baseline_acm_certificates = {
# remote_desktop_wildcard_cert = {
# # domain_name limited to 64 chars so use modernisation platform domain for this
# # and put the wildcard in the san
# domain_name = module.environment.domains.public.modernisation_platform
# subject_alternate_names = [
# "*.${module.environment.domains.public.application_environment}",
# "hmppgw2.justice.gov.uk",
# "*.hmppgw2.justice.gov.uk",
# ]
# external_validation_records_created = false
# cloudwatch_metric_alarms = module.baseline_presets.cloudwatch_metric_alarms.acm
# tags = {
# description = "wildcard cert for remote desktop services"
# }
# }
remote_desktop_wildcard_cert = {
# domain_name limited to 64 chars so use modernisation platform domain for this
# and put the wildcard in the san
domain_name = module.environment.domains.public.modernisation_platform
subject_alternate_names = [
"*.${module.environment.domains.public.application_environment}",
"*.development.hmpps-domain.service.justice.gov.uk",
"hmppgw2.justice.gov.uk",
"*.hmppgw2.justice.gov.uk",
]
external_validation_records_created = false
cloudwatch_metric_alarms = module.baseline_presets.cloudwatch_metric_alarms.acm
tags = {
description = "wildcard cert for hmpps domain load balancer"
}
}
}

baseline_ec2_autoscaling_groups = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,21 +5,20 @@ locals {
preproduction_config = {

baseline_acm_certificates = {
# remote_desktop_wildcard_cert = {
#  # domain_name limited to 64 chars so use modernisation platform domain for this
# # and put the wildcard in the san
# domain_name = module.environment.domains.public.modernisation_platform
# subject_alternate_names = [
# "*.${module.environment.domains.public.application_environment}",
# "pp.hmpps-az-gw1.justice.gov.uk",
#  "*.pp.hmpps-az-gw1.justice.gov.uk",
# ]
# external_validation_records_created = false
#  cloudwatch_metric_alarms = module.baseline_presets.cloudwatch_metric_alarms.acm
#  tags = {
#  description = "wildcard cert for remote desktop services"
#  }
# }
remote_desktop_wildcard_cert = {
# domain_name limited to 64 chars so use modernisation platform domain for this
# and put the wildcard in the san
domain_name = module.environment.domains.public.modernisation_platform
subject_alternate_names = [
"*.${module.environment.domains.public.application_environment}",
"*.preproduction.hmpps-domain.service.justice.gov.uk",
]
external_validation_records_created = false
cloudwatch_metric_alarms = module.baseline_presets.cloudwatch_metric_alarms.acm
tags = {
description = "wildcard cert for hmpps domain load balancer"
}
}
}

baseline_lbs = {
Expand Down
37 changes: 22 additions & 15 deletions terraform/environments/hmpps-domain-services/locals_production.tf
Original file line number Diff line number Diff line change
Expand Up @@ -5,21 +5,22 @@ locals {
production_config = {

baseline_acm_certificates = {
# remote_desktop_wildcard_cert = {
# # domain_name limited to 64 chars so use modernisation platform domain for this
# # and put the wildcard in the san
# domain_name = module.environment.domains.public.modernisation_platform
# subject_alternate_names = [
# "*.${module.environment.domains.public.application_environment}",
# "hmpps-az-gw1.justice.gov.uk",
# "*.hmpps-az-gw1.justice.gov.uk",
# ]
# external_validation_records_created = false
# cloudwatch_metric_alarms = module.baseline_presets.cloudwatch_metric_alarms.acm
#  tags = {
# description = "wildcard cert for remote desktop services"
# }
# }
remote_desktop_wildcard_cert = {
# domain_name limited to 64 chars so use modernisation platform domain for this
# and put the wildcard in the san
domain_name = module.environment.domains.public.modernisation_platform
subject_alternate_names = [
"*.${module.environment.domains.public.application_environment}",
"*.hmpps-domain.service.justice.gov.uk",
"hmpps-az-gw1.justice.gov.uk",
"*.hmpps-az-gw1.justice.gov.uk",
]
external_validation_records_created = false
cloudwatch_metric_alarms = module.baseline_presets.cloudwatch_metric_alarms.acm
tags = {
description = "wildcard cert for hmpps domain load balancer"
}
}
}

baseline_lbs = {
Expand Down Expand Up @@ -74,6 +75,12 @@ locals {

baseline_route53_zones = {
"hmpps-domain.service.justice.gov.uk" = {
records = [
{ name = "development", type = "NS", ttl = "86400", records = [] },
{ name = "test", type = "NS", ttl = "86400", records = ["ns-134.awsdns-16.com", "ns-1426.awsdns-50.org", "ns-1934.awsdns-49.co.uk", "ns-927.awsdns-51.net", ] },
{ name = "preproduction", type = "NS", ttl = "86400", records = ["ns-1509.awsdns-60.org", "ns-1925.awsdns-48.co.uk", "ns-216.awsdns-27.com", "ns-753.awsdns-30.net", ] },
]

lb_alias_records = [
{ name = "rdgateway1", type = "A", lbs_map_key = "public" },
{ name = "rdweb1", type = "A", lbs_map_key = "public" },
Expand Down
31 changes: 16 additions & 15 deletions terraform/environments/hmpps-domain-services/locals_test.tf
Original file line number Diff line number Diff line change
Expand Up @@ -12,21 +12,22 @@ locals {
}

baseline_acm_certificates = {
# remote_desktop_wildcard_cert = {
# # domain_name limited to 64 chars so use modernisation platform domain for this
# # and put the wildcard in the san
# domain_name = module.environment.domains.public.modernisation_platform
# subject_alternate_names = [
# "*.${module.environment.domains.public.application_environment}",
# "hmppgw1.justice.gov.uk",
# "*.hmppgw1.justice.gov.uk",
#  ]
# external_validation_records_created = false
# cloudwatch_metric_alarms = module.baseline_presets.cloudwatch_metric_alarms.acm
# tags = {
#  description = "wildcard cert for remote desktop services"
#  }
# }
remote_desktop_wildcard_cert = {
# domain_name limited to 64 chars so use modernisation platform domain for this
# and put the wildcard in the san
domain_name = module.environment.domains.public.modernisation_platform
subject_alternate_names = [
"*.${module.environment.domains.public.application_environment}",
"*.test.hmpps-domain.service.justice.gov.uk",
"hmppgw1.justice.gov.uk",
"*.hmppgw1.justice.gov.uk",
]
external_validation_records_created = false
cloudwatch_metric_alarms = module.baseline_presets.cloudwatch_metric_alarms.acm
tags = {
description = "wildcard cert for hmpps domain load balancer"
}
}
}

baseline_ec2_autoscaling_groups = {
Expand Down
Loading