From db6a5131903106538ec682491d0d4a3d21ec6c35 Mon Sep 17 00:00:00 2001
From: Sang Le <sang@go1.com>
Date: Wed, 16 Jun 2021 13:06:32 +1000
Subject: [PATCH] Fix ingress rules for api networking.k8s.io/v1

---
 examples/ingress.jsonnet | 18 +++++++++++++++---
 1 file changed, 15 insertions(+), 3 deletions(-)

diff --git a/examples/ingress.jsonnet b/examples/ingress.jsonnet
index a2e26cd7..09711a0e 100644
--- a/examples/ingress.jsonnet
+++ b/examples/ingress.jsonnet
@@ -54,10 +54,14 @@ local kp =
           host: 'alertmanager.example.com',
           http: {
             paths: [{
+              path: '/',
+              pathType: 'Prefix',
               backend: {
                 service: {
                   name: 'alertmanager-main',
-                  port: 'web',
+                  port: {
+                    name: 'web'
+                  },
                 },
               },
             }],
@@ -71,10 +75,14 @@ local kp =
           host: 'grafana.example.com',
           http: {
             paths: [{
+              path: '/',
+              pathType: 'Prefix',
               backend: {
                 service: {
                   name: 'grafana',
-                  port: 'http',
+                  port: {
+                    name: 'http'
+                  },
                 },
               },
             }],
@@ -88,10 +96,14 @@ local kp =
           host: 'prometheus.example.com',
           http: {
             paths: [{
+              path: '/',
+              pathType: 'Prefix',
               backend: {
                 service: {
                   name: 'prometheus-k8s',
-                  port: 'web',
+                  port: {
+                    name: 'web'
+                  },
                 },
               },
             }],
-- 
GitLab