From 8f64c310c87d76a1cac62dad8f59378ca84b56c7 Mon Sep 17 00:00:00 2001 From: Dmytro Bondar Date: Thu, 2 Jul 2026 10:36:07 +0200 Subject: [PATCH] fix: update HTTPRoute template to correctly define backendRefs and matches --- charts/base/Chart.yaml | 2 +- charts/base/README.md | 2 +- charts/base/templates/httproute.yaml | 16 +++++++++------- 3 files changed, 11 insertions(+), 9 deletions(-) diff --git a/charts/base/Chart.yaml b/charts/base/Chart.yaml index 8e573cb..321c0ec 100644 --- a/charts/base/Chart.yaml +++ b/charts/base/Chart.yaml @@ -2,7 +2,7 @@ apiVersion: v2 name: base description: Base Helm chart for Kubernetes - fully values-driven. type: application -version: 0.2.0 +version: 0.2.1 maintainers: - name: bonddim sources: diff --git a/charts/base/README.md b/charts/base/README.md index 7d64550..9d430fb 100644 --- a/charts/base/README.md +++ b/charts/base/README.md @@ -1,6 +1,6 @@ # base -![Version: 0.2.0](https://img.shields.io/badge/Version-0.2.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) +![Version: 0.2.1](https://img.shields.io/badge/Version-0.2.1-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) Base Helm chart for Kubernetes - fully values-driven. diff --git a/charts/base/templates/httproute.yaml b/charts/base/templates/httproute.yaml index 2c8d381..4a85e4f 100644 --- a/charts/base/templates/httproute.yaml +++ b/charts/base/templates/httproute.yaml @@ -14,15 +14,17 @@ spec: {{- end }} rules: {{- range .Values.httpRoute.rules }} - - {{- with .matches }} - matches: {{- toYaml . | nindent 8 }} - {{- end }} + - backendRefs: + - group: "" + kind: Service + name: {{ include "base.fullname" $ }} + port: {{ $.Values.service.port }} + weight: 1 {{- with .filters }} filters: {{- toYaml . | nindent 8 }} {{- end }} - backendRefs: - - name: {{ include "base.fullname" $ }} - port: {{ $.Values.service.port }} - weight: 1 + {{- with .matches }} + matches: {{- toYaml . | nindent 8 }} + {{- end }} {{- end }} {{- end }}