From 9f872ebea053c00c18fc4034cc3382900a1f1055 Mon Sep 17 00:00:00 2001 From: "pierre.geeraert" Date: Mon, 12 Oct 2026 18:14:23 +0100 Subject: [PATCH] cleanup --- infrastructure/module.tf | 31 ------------------------------- 1 file changed, 31 deletions(-) diff --git a/infrastructure/module.tf b/infrastructure/module.tf index 068b1ee..4fc2685 100644 --- a/infrastructure/module.tf +++ b/infrastructure/module.tf @@ -122,38 +122,7 @@ variable "storage_path" { } } -locals { - pvc_list = flatten([ - for key, value in var.kubernetes : [ - for index, pvc in value.pvc : { - key = "${coalesce(value.namespace, value.connected_namespace, key)}/${pvc.name}" - index = index - pvc = pvc.pvc - name = pvc.name - pvc_size = pvc.pvc_size - mount_path = pvc.mount_path - storage_class_name = pvc.storage_class_name - annotations_fileType = pvc.annotations_fileType - existing_pvc = pvc.existing_pvc - sub_path = pvc.sub_path - namespace = coalesce(value.namespace, value.connected_namespace, key) - }] if value.enabled == true && value.pvc != null - ]) - # group duplicates instead of throwing an error - pvc_map_grouped = { - for p in local.pvc_list : - p.key => p... - } - - # keep only one PVC per key (take the first) - pvc_map = { - for k, list in local.pvc_map_grouped : - k => list[0] - } - - pvc_details = values(local.pvc_map) -} locals { env_details = flatten([