Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tpl statekey & extra env vars #146

Merged
merged 4 commits into from
Oct 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
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
2 changes: 1 addition & 1 deletion charts/port-k8s-exporter/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v2
name: port-k8s-exporter
description: A Helm chart for Port Kubernetes Exporter
type: application
version: 0.2.35
version: 0.2.36
appVersion: "0.4.2"
home: https://getport.io/
sources:
Expand Down
2 changes: 1 addition & 1 deletion charts/port-k8s-exporter/templates/configmap.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{{- if eq .Values.configMap.create true -}}
{{- $stateKey := lower (default (uuidv4 | replace "-" "") .Values.stateKey) -}}
{{- $stateKey := lower (default (uuidv4 | replace "-" "") (tpl .Values.stateKey $)) -}}
{{- $config_lookup := (lookup "v1" "ConfigMap" .Release.Namespace (include "port-k8s-exporter.configMapName" .)) -}}
{{- if (($config_lookup).data).state_key -}}
{{- $stateKey = $config_lookup.data.state_key -}}
Expand Down
4 changes: 2 additions & 2 deletions charts/port-k8s-exporter/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,8 @@ spec:
- name: EVENT_LISTENER_AUTHENTICATION_MECHANISM
value: {{ .Values.eventListener.authenticationMechanism | quote }}
{{- end }}
{{- with .Values.extraEnv }}
{{- toYaml . | nindent 12 }}
{{- if .Values.extraEnv }}
{{- tpl (toYaml .Values.extraEnv) $ | nindent 12 }}
{{- end }}
volumeMounts:
- name: config-volume
Expand Down
Loading