Skip to content

Commit

Permalink
refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
mrlockstar committed Nov 13, 2024
1 parent 3171267 commit 2627c59
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 19 deletions.
6 changes: 1 addition & 5 deletions infrastructure/tf-audit/outputs.tf
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
output "log_analytics_workspace_id" {
value = {
for k, v in module.log_analytics_workspace_audit : k => {
id = v.id
}
}
value = { for k, v in module.log_analytics_workspace_audit : k => v.id }
}
2 changes: 1 addition & 1 deletion infrastructure/tf-audit/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ variable "HUB_BACKEND_AZURE_STORAGE_ACCOUNT_CONTAINER_NAME" {
type = string
}

variable "HUB_BACKEND_AZURE_STORAGE_KEY" {
variable "HUB_BACKEND_AZURE_STORAGE_ACCOUNT_KEY" {
description = "The name of the Statefile for the hub resources"
type = string
}
Expand Down
3 changes: 1 addition & 2 deletions infrastructure/tf-core/environments/development.tfvars
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,6 @@ function_apps = {
db_connection_string = "ServiceInsightsDbConnectionString"
}

# does not build currently
ReceiveData = {
name_suffix = "receive-data"
function_endpoint_name = "ReceiveData"
Expand Down Expand Up @@ -296,7 +295,7 @@ function_apps = {

GetOrganisationData = {
name_suffix = "get-organisation-data"
function_endpoint_name = "GetOrganisationData "
function_endpoint_name = "GetOrganisationData"
app_service_plan_key = "ReferenceDataService"
db_connection_string = "ServiceInsightsDbConnectionString"
}
Expand Down
3 changes: 1 addition & 2 deletions infrastructure/tf-core/function_app.tf
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@ module "functionapp" {
resource_group_name = azurerm_resource_group.core[each.value.region_key].name
location = each.value.region_key

# to go in later
log_analytics_workspace_id = data.terraform_remote_state.audit.outputs.log_analytics_workspace_id[local.primary_region].id
log_analytics_workspace_id = data.terraform_remote_state.audit.outputs.log_analytics_workspace_id[local.primary_region]

app_settings = local.app_settings[each.value.region_key][each.value.function_key]

Expand Down
12 changes: 3 additions & 9 deletions infrastructure/tf-core/variables.tf
Original file line number Diff line number Diff line change
@@ -1,19 +1,13 @@
# variable "AUDIT_BACKEND_AZURE_SUBSCRIPTION_ID" {
# description = "ID of the Azure Storage Account for the audit backend"
# type = string
# }
variable "AUDIT_BACKEND_AZURE_STORAGE_ACCOUNT_NAME" {
description = "The name of the Azure Storage Account for the audit backend"
type = string
}

variable "AUDIT_BACKEND_AZURE_STORAGE_ACCOUNT_CONTAINER_NAME" {
description = "The name of the container in the Audit Azure Storage Account for the backend"
type = string
}
# variable "AUDIT_BACKEND_AZURE_STORAGE_KEY" {
# description = "The name of the Statefile for the audit resources"
# type = string
# }

variable "AUDIT_BACKEND_AZURE_RESOURCE_GROUP_NAME" {
description = "The name of the audit resource group for the Azure Storage Account"
type = string
Expand Down Expand Up @@ -49,7 +43,7 @@ variable "HUB_BACKEND_AZURE_STORAGE_ACCOUNT_CONTAINER_NAME" {
type = string
}

variable "HUB_BACKEND_AZURE_STORAGE_KEY" {
variable "HUB_BACKEND_AZURE_STORAGE_ACCOUNT_KEY" {
description = "The name of the Statefile for the hub resources"
type = string
}
Expand Down

0 comments on commit 2627c59

Please sign in to comment.