From bd8e318691e44e001e03a867c8d6386b181fcde0 Mon Sep 17 00:00:00 2001 From: Zvikan Date: Fri, 18 Nov 2022 15:33:02 -0600 Subject: [PATCH 1/4] fix: let fluentbit create cw log group in example --- examples/complete-kubernetes-addons/main.tf | 1 + 1 file changed, 1 insertion(+) diff --git a/examples/complete-kubernetes-addons/main.tf b/examples/complete-kubernetes-addons/main.tf index d5656e86e9..e383692c09 100644 --- a/examples/complete-kubernetes-addons/main.tf +++ b/examples/complete-kubernetes-addons/main.tf @@ -128,6 +128,7 @@ module "eks_blueprints_kubernetes_addons" { amazon_prometheus_workspace_endpoint = module.managed_prometheus.workspace_prometheus_endpoint enable_aws_for_fluentbit = true + aws_for_fluentbit_create_cw_log_group = false aws_for_fluentbit_cw_log_group_retention = 30 aws_for_fluentbit_helm_config = { create_namespace = true From 230175e62fc0387011b683a5d63a1a29ebfb9403 Mon Sep 17 00:00:00 2001 From: Zvikan Date: Fri, 18 Nov 2022 15:54:04 -0600 Subject: [PATCH 2/4] fix: output try output value --- examples/complete-kubernetes-addons/outputs.tf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/complete-kubernetes-addons/outputs.tf b/examples/complete-kubernetes-addons/outputs.tf index cbeeef8c63..d2c6aa2069 100644 --- a/examples/complete-kubernetes-addons/outputs.tf +++ b/examples/complete-kubernetes-addons/outputs.tf @@ -15,5 +15,5 @@ output "kyverno_addon" { output "kyverno_values" { description = "Values used in the Kyverno Helm release" - value = jsondecode(module.eks_blueprints_kubernetes_addons.kyverno.release_metadata[0].values) + value = try(jsondecode(module.eks_blueprints_kubernetes_addons.kyverno.release_metadata[0].values), null) } From d14f915cb568b212afab073719783b954b19b4b9 Mon Sep 17 00:00:00 2001 From: Zvikan Date: Fri, 18 Nov 2022 15:56:15 -0600 Subject: [PATCH 3/4] fix: prometheus try access element --- modules/kubernetes-addons/prometheus/main.tf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/kubernetes-addons/prometheus/main.tf b/modules/kubernetes-addons/prometheus/main.tf index a06d46a15a..3621b4438d 100644 --- a/modules/kubernetes-addons/prometheus/main.tf +++ b/modules/kubernetes-addons/prometheus/main.tf @@ -109,7 +109,7 @@ module "irsa_amp_ingest" { kubernetes_namespace = local.namespace kubernetes_service_account = local.ingest_service_account - irsa_iam_policies = [aws_iam_policy.ingest[0].arn] + irsa_iam_policies = [try(aws_iam_policy.ingest[0].arn,"")] irsa_iam_role_path = var.addon_context.irsa_iam_role_path irsa_iam_permissions_boundary = var.addon_context.irsa_iam_permissions_boundary eks_cluster_id = var.addon_context.eks_cluster_id From fcfe0849f28c73e65a6abd7df96ad6c0eda22e7c Mon Sep 17 00:00:00 2001 From: Zvikan Date: Fri, 18 Nov 2022 17:30:17 -0600 Subject: [PATCH 4/4] chore: pre-commit fix --- modules/kubernetes-addons/prometheus/main.tf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/kubernetes-addons/prometheus/main.tf b/modules/kubernetes-addons/prometheus/main.tf index 3621b4438d..815257fe9d 100644 --- a/modules/kubernetes-addons/prometheus/main.tf +++ b/modules/kubernetes-addons/prometheus/main.tf @@ -109,7 +109,7 @@ module "irsa_amp_ingest" { kubernetes_namespace = local.namespace kubernetes_service_account = local.ingest_service_account - irsa_iam_policies = [try(aws_iam_policy.ingest[0].arn,"")] + irsa_iam_policies = [try(aws_iam_policy.ingest[0].arn, "")] irsa_iam_role_path = var.addon_context.irsa_iam_role_path irsa_iam_permissions_boundary = var.addon_context.irsa_iam_permissions_boundary eks_cluster_id = var.addon_context.eks_cluster_id