Enable agent to kubelet connection to use hostname (#112)

Co-authored-by: Marco Franssen <[email protected]>
This commit is contained in:
kfox1111
2023-11-28 08:43:09 +01:00
committed by GitHub
co-authored by Marco Franssen
parent e68f6170a6
commit d936293d50
5 changed files with 104 additions and 84 deletions
@@ -104,3 +104,16 @@ Create the name of the service account to use
{{- print .Values.socketPath }}
{{- end }}
{{- define "spire-agent.connect-by-hostname" -}}
{{- if ne .Values.kubeletConnectByHostname "" }}
{{- if eq (.Values.kubeletConnectByHostname | toString) "true" }}
{{- printf "true" }}
{{- else }}
{{- printf "false" }}
{{- end }}
{{- else if (dig "openshift" false .Values.global) }}
{{- printf "true" }}
{{- else }}
{{- printf "false" }}
{{- end }}
{{- end }}