Skip to content

Commit c492051

Browse files
committed
[library-chart] Removing Service and Ingresses from suspended Charts as they no longer have an active endpoint
1 parent 45d77aa commit c492051

File tree

3 files changed

+7
-1
lines changed

3 files changed

+7
-1
lines changed

charts/library-chart/Chart.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
apiVersion: v2
22
name: library-chart
3-
version: 1.5.43
3+
version: 1.5.44
44
type: library

charts/library-chart/templates/_ingress.tpl

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ acme.cert-manager.io/http01-ingress-class: {{ .Values.ingress.ingressClassName }
3939
{{/* Template to generate a standard Ingress */}}
4040
{{- define "library-chart.ingress" -}}
4141
{{- if .Values.ingress.enabled -}}
42+
{{- if or .Values.autoscaling.enabled (not .Values.global.suspend) }}
4243
{{- $fullName := include "library-chart.fullname" . -}}
4344
{{- $svcPort := .Values.networking.service.port -}}
4445
apiVersion: networking.k8s.io/v1
@@ -74,10 +75,12 @@ spec:
7475
number: {{ $svcPort }}
7576
{{- end }}
7677
{{- end }}
78+
{{- end }}
7779

7880
{{/* Template to generate a custom Ingress */}}
7981
{{- define "library-chart.ingressUser" -}}
8082
{{- if .Values.ingress.enabled -}}
83+
{{- if or .Values.autoscaling.enabled (not .Values.global.suspend) }}
8184
{{- if and .Values.networking.user .Values.networking.user.enabled -}}
8285
{{- $userPorts := list -}}
8386
{{- if or .Values.networking.user.ports .Values.networking.user.port -}}
@@ -134,6 +137,7 @@ spec:
134137
{{- end }}
135138
{{- end }}
136139
{{- end }}
140+
{{- end }}
137141

138142
{{/* Template to generate an Ingress for the Spark UI */}}
139143
{{- define "library-chart.ingressSpark" -}}

charts/library-chart/templates/_service.tpl

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
{{/* Template to generate a Service */}}
44
{{- define "library-chart.service" -}}
5+
{{- if or .Values.autoscaling.enabled (not .Values.global.suspend) }}
56
{{- $userPorts := list -}}
67
{{- if and .Values.networking.user .Values.networking.user.enabled (or .Values.networking.user.ports .Values.networking.user.port) -}}
78
{{- $userPorts = .Values.networking.user.ports | default (list .Values.networking.user.port) -}}
@@ -40,4 +41,5 @@ spec:
4041
{{- end }}
4142
selector:
4243
{{- include "library-chart.selectorLabels" . | nindent 4 }}
44+
{{- end -}}
4345
{{- end }}

0 commit comments

Comments
 (0)