Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Fix Ingress
serviceName and servicePort were removed and pathType is required in 1.22: https://kubernetes.io/docs/reference/using-api/deprecation-guide/#ingress-v122

Signed-off-by: Sven Schliesing <sven@schliesing.de>
  • Loading branch information
muffl0n committed Jan 31, 2025
commit e31db21ca260da353ff888ffd37c093400ed6d71
13 changes: 6 additions & 7 deletions demo-targets/http-webhook/templates/ingress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,7 @@
{{- if .Values.ingress.enabled -}}
{{- $fullName := include "http-webhook.fullname" . -}}
{{- $svcPort := .Values.service.port -}}
{{- if semverCompare ">=1.14-0" .Capabilities.KubeVersion.GitVersion -}}
apiVersion: networking.k8s.io/v1beta1
{{- else -}}
apiVersion: extensions/v1beta1
{{- end }}
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: {{ $fullName }}
Expand Down Expand Up @@ -37,9 +33,12 @@ spec:
paths:
{{- range .paths }}
- path: {{ . }}
pathType: Prefix
backend:
serviceName: {{ $fullName }}
servicePort: {{ $svcPort }}
service:
name: {{ $fullName }}
port:
name: http
{{- end }}
{{- end }}
{{- end }}