fix: Helm giving linting error when no ingress or ingressGrpc extraPaths are given (#435)

* Added conditionals for ingress extraPaths

* Added conditionals for ingressGrpc extraPaths

* Version bump
This commit is contained in:
Ertugrul Karademir 2020-09-01 23:41:22 +01:00 committed by GitHub
parent ffc9220f04
commit b9af202660
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 14 additions and 5 deletions

View file

@ -2,7 +2,7 @@ apiVersion: v1
appVersion: "1.6.2"
description: A Helm chart for ArgoCD, a declarative, GitOps continuous delivery tool for Kubernetes.
name: argo-cd
version: 2.6.2
version: 2.6.3
home: https://github.com/argoproj/argo-helm
icon: https://raw.githubusercontent.com/argoproj/argo/master/docs/assets/argo.png
keywords:

View file

@ -2,6 +2,7 @@
{{- $serviceName := include "argo-cd.server.fullname" . -}}
{{- $servicePort := ternary .Values.server.service.servicePortHttps .Values.server.service.servicePortHttp .Values.server.ingressGrpc.https -}}
{{- $paths := .Values.server.ingressGrpc.paths -}}
{{- $extraPaths := .Values.server.ingressGrpc.extraPaths -}}
{{- if .Capabilities.APIVersions.Has "networking.k8s.io/v1beta1" }}
apiVersion: networking.k8s.io/v1beta1
{{ else }}
@ -33,7 +34,9 @@ spec:
- host: {{ $host }}
http:
paths:
{{- toYaml .Values.server.ingressGrpc.extraPaths | nindent 10 }}
{{- if $extraPaths }}
{{- toYaml $extraPaths | nindent 10 }}
{{- end -}}
{{- range $p := $paths }}
- path: {{ $p }}
backend:
@ -44,7 +47,9 @@ spec:
{{- else }}
- http:
paths:
{{- toYaml .Values.server.ingressGrpc.extraPaths | nindent 10 }}
{{- if $extraPaths }}
{{- toYaml $extraPaths | nindent 10 }}
{{- end -}}
{{- range $p := $paths }}
- path: {{ $p }}
backend:
@ -56,4 +61,4 @@ spec:
tls:
{{- toYaml .Values.server.ingressGrpc.tls | nindent 4 }}
{{- end -}}
{{- end -}}
{{- end -}}

View file

@ -34,7 +34,9 @@ spec:
- host: {{ $host }}
http:
paths:
{{- if $extraPaths }}
{{- toYaml $extraPaths | nindent 10 }}
{{- end }}
{{- range $p := $paths }}
- path: {{ $p }}
backend:
@ -45,7 +47,9 @@ spec:
{{- else }}
- http:
paths:
{{- if $extraPaths }}
{{- toYaml $extraPaths | nindent 10 }}
{{- end }}
{{- range $p := $paths }}
- path: {{ $p }}
backend:
@ -57,4 +61,4 @@ spec:
tls:
{{- toYaml .Values.server.ingress.tls | nindent 4 }}
{{- end -}}
{{- end -}}
{{- end -}}