Compare commits

2 Commits

Author SHA1 Message Date
7155146e00 Fix service name for webhook ingress
All checks were successful
continuous-integration/drone/push Build is passing
continuous-integration/drone/tag Build is passing
2022-11-16 16:42:09 +03:00
3639069556 Revert "Remove $fullName var from ingress templates"
This reverts commit 92f8d4442c.
2022-11-16 16:41:43 +03:00
2 changed files with 8 additions and 6 deletions

View File

@ -1,4 +1,5 @@
{{- if .Values.n8n.ingress.enabled -}} {{- if .Values.n8n.ingress.enabled -}}
{{- $fullName := include "n8n.fullname" . -}}
{{- $svcPort := .Values.n8n.service.port -}} {{- $svcPort := .Values.n8n.service.port -}}
{{- if and .Values.n8n.ingress.className (not (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion)) }} {{- if and .Values.n8n.ingress.className (not (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion)) }}
{{- if not (hasKey .Values.n8n.ingress.annotations "kubernetes.io/ingress.class") }} {{- if not (hasKey .Values.n8n.ingress.annotations "kubernetes.io/ingress.class") }}
@ -14,7 +15,7 @@ apiVersion: extensions/v1beta1
{{- end }} {{- end }}
kind: Ingress kind: Ingress
metadata: metadata:
name: {{ include "n8n.fullname" . }} name: {{ $fullName }}
labels: labels:
{{- include "n8n.labels" . | nindent 4 }} {{- include "n8n.labels" . | nindent 4 }}
{{- with .Values.n8n.ingress.annotations }} {{- with .Values.n8n.ingress.annotations }}
@ -46,11 +47,11 @@ spec:
backend: backend:
{{- if semverCompare ">=1.19-0" $.Capabilities.KubeVersion.GitVersion }} {{- if semverCompare ">=1.19-0" $.Capabilities.KubeVersion.GitVersion }}
service: service:
name: {{ include "n8n.fullname" . }} name: {{ $fullName }}
port: port:
number: {{ $svcPort }} number: {{ $svcPort }}
{{- else }} {{- else }}
serviceName: {{ include "n8n.fullname" . }} serviceName: {{ $fullName }}
servicePort: {{ $svcPort }} servicePort: {{ $svcPort }}
{{- end }} {{- end }}
{{- end }} {{- end }}

View File

@ -1,4 +1,5 @@
{{- if .Values.webhook.ingress.enabled -}} {{- if .Values.webhook.ingress.enabled -}}
{{- $fullName := include "n8n.fullname" . -}}
{{- $svcPort := .Values.webhook.service.port -}} {{- $svcPort := .Values.webhook.service.port -}}
{{- if and .Values.webhook.ingress.className (not (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion)) }} {{- if and .Values.webhook.ingress.className (not (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion)) }}
{{- if not (hasKey .Values.webhook.ingress.annotations "kubernetes.io/ingress.class") }} {{- if not (hasKey .Values.webhook.ingress.annotations "kubernetes.io/ingress.class") }}
@ -14,7 +15,7 @@ apiVersion: extensions/v1beta1
{{- end }} {{- end }}
kind: Ingress kind: Ingress
metadata: metadata:
name: {{ include "n8n.fullname" . }}-webhook name: {{ $fullName }}-webhook
labels: labels:
{{- include "n8n.labels" . | nindent 4 }} {{- include "n8n.labels" . | nindent 4 }}
{{- with .Values.webhook.ingress.annotations }} {{- with .Values.webhook.ingress.annotations }}
@ -46,11 +47,11 @@ spec:
backend: backend:
{{- if semverCompare ">=1.19-0" $.Capabilities.KubeVersion.GitVersion }} {{- if semverCompare ">=1.19-0" $.Capabilities.KubeVersion.GitVersion }}
service: service:
name: {{ include "n8n.fullname" . }}-webhook name: {{ $fullName }}-webhook
port: port:
number: {{ $svcPort }} number: {{ $svcPort }}
{{- else }} {{- else }}
serviceName: {{ include "n8n.fullname" . }}-webhook serviceName: {{ $fullName }}-webhook
servicePort: {{ $svcPort }} servicePort: {{ $svcPort }}
{{- end }} {{- end }}
{{- end }} {{- end }}