Skip to content

Commit

Permalink
Add data.gov.uk to www.data.gov.uk redirect location header
Browse files Browse the repository at this point in the history
  • Loading branch information
AgaDufrat committed Jan 26, 2024
1 parent 4f6a885 commit c726670
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions modules/datagovuk/service.tf
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,15 @@ resource "fastly_service_vcl" "service" {
}
}

header {
name = "${local.template_values["environment"]}.data.gov.uk to www.${local.template_values["environment"]}.data.gov.uk redirect location header"
action = "set"
type = "response"
destination = "http.Location"
source = "\"https://www.${local.template_values["environment"]}.data.gov.uk\" + req.url"
response_condition = "${local.template_values["environment"]}.data.gov.uk to www.${local.template_values["environment"]}.data.gov.uk redirect response condition"
}

dynamic "logging_splunk" {
for_each = {
for splunk in lookup(var.secrets, "splunk", []) : splunk.name => splunk
Expand Down

0 comments on commit c726670

Please sign in to comment.