From 7dfb44a1b0cf7b9b101406d9c259bd7c86253d11 Mon Sep 17 00:00:00 2001 From: githubjianli <51385385+githubjianli@users.noreply.github.com> Date: Thu, 16 Nov 2023 13:27:20 -0800 Subject: [PATCH] fix: fix syntax --- k8s.tf | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/k8s.tf b/k8s.tf index a17ba48..8b7b51b 100644 --- a/k8s.tf +++ b/k8s.tf @@ -33,9 +33,11 @@ resource "kubernetes_ingress_v1" "beekeeper" { path { path = var.k8s_path_cleanup_ingress_path backend { - name = kubernetes_service.beekeeper_path_cleanup[0].metadata[0].name - port { + service { + name = kubernetes_service.beekeeper_path_cleanup[0].metadata[0].name + port { number = kubernetes_service.beekeeper_path_cleanup[0].spec[0].port[0].target_port + } } } } @@ -48,9 +50,11 @@ resource "kubernetes_ingress_v1" "beekeeper" { path { path = var.k8s_metadata_cleanup_ingress_path backend { - name = kubernetes_service.beekeeper_metadata_cleanup[0].metadata[0].name - port { + service { + name = kubernetes_service.beekeeper_metadata_cleanup[0].metadata[0].name + port { number = kubernetes_service.beekeeper_metadata_cleanup[0].spec[0].port[0].target_port + } } } } @@ -63,9 +67,11 @@ resource "kubernetes_ingress_v1" "beekeeper" { path { path = var.k8s_scheduler_apiary_ingress_path backend { - name = kubernetes_service.beekeeper_scheduler_apiary[0].metadata[0].name - port { + service { + name = kubernetes_service.beekeeper_scheduler_apiary[0].metadata[0].name + port { number = kubernetes_service.beekeeper_scheduler_apiary[0].spec[0].port[0].target_port + } } } }