diff --git a/charts/library-chart/Chart.yaml b/charts/library-chart/Chart.yaml index ae671e6d..ae1c5372 100644 --- a/charts/library-chart/Chart.yaml +++ b/charts/library-chart/Chart.yaml @@ -1,4 +1,4 @@ apiVersion: v2 name: library-chart -version: 1.5.23 +version: 1.5.24 type: library diff --git a/charts/library-chart/templates/_secret.tpl b/charts/library-chart/templates/_secret.tpl index ff0c17bd..1b3212bd 100644 --- a/charts/library-chart/templates/_secret.tpl +++ b/charts/library-chart/templates/_secret.tpl @@ -30,6 +30,39 @@ stringData: {{- end }} {{- end }} +{{/* Create the name of the secret Proxy to use */}} +{{- define "library-chart.secretNameProxy" -}} +{{ if (.Values.proxy).enabled}} +{{- $name:= (printf "%s-secretproxy" (include "library-chart.fullname" .) ) }} +{{- default $name (printf "%s-secretproxy" (include "library-chart.fullname" .) ) }} +{{- end }} +{{- end }} + +{{/* Template to generate a secret for proxy */}} +{{- define "library-chart.secretProxy" -}} +{{ if (.Values.proxy).enabled}} +apiVersion: v1 +kind: Secret +metadata: + name: {{ include "library-chart.secretNameProxy" . }} + labels: + {{- include "library-chart.labels" . | nindent 4 }} +stringData: + {{- if .Values.proxy.httpProxy }} + http_proxy: {{ .Values.proxy.httpProxy | quote }} + HTTP_PROXY: {{ .Values.proxy.httpProxy }} + {{- end }} + {{- if .Values.proxy.httpsProxy }} + https_proxy: {{ .Values.proxy.httpsProxy | quote }} + HTTPS_PROXY: {{ .Values.proxy.httpsProxy | quote }} + {{- end }} + {{- if .Values.proxy.noProxy }} + no_proxy: {{ .Values.proxy.noProxy | quote }} + NO_PROXY: {{ .Values.proxy.noProxy | quote }} +{{- end }} +{{- end }} +{{- end }} + {{/* Create the name of the secret Vault to use */}} {{- define "library-chart.secretNameVault" -}} {{- if .Values.vault.enabled }}