Add teleport
This commit is contained in:
@@ -0,0 +1,46 @@
|
||||
{{- define "teleport.kube.agent.isUpgrade" -}}
|
||||
{{- /* Checks if action is an upgrade from an old release that didn't support Secret storage */}}
|
||||
{{- if .Release.IsUpgrade }}
|
||||
{{- $deployment := (lookup "apps/v1" "Deployment" .Release.Namespace .Release.Name ) -}}
|
||||
{{- if ($deployment) }}
|
||||
true
|
||||
{{- else if .Values.unitTestUpgrade }}
|
||||
true
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end -}}
|
||||
{{/*
|
||||
Create the name of the service account to use
|
||||
if serviceAccount is not defined or serviceAccount.name is empty, use .Release.Name
|
||||
*/}}
|
||||
{{- define "teleport-kube-agent.serviceAccountName" -}}
|
||||
{{- coalesce .Values.serviceAccount.name .Values.serviceAccountName .Release.Name -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Create the name of the service account to use for the post-delete hook
|
||||
if serviceAccount is not defined or serviceAccount.name is empty, use .Release.Name-delete-hook
|
||||
*/}}
|
||||
{{- define "teleport-kube-agent.deleteHookServiceAccountName" -}}
|
||||
{{- coalesce .Values.serviceAccount.name .Values.serviceAccountName (printf "%s-delete-hook" .Release.Name) -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- define "teleport-kube-agent.version" -}}
|
||||
{{- if .Values.teleportVersionOverride -}}
|
||||
{{- .Values.teleportVersionOverride -}}
|
||||
{{- else -}}
|
||||
{{- .Chart.Version -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- define "teleport-kube-agent.baseImage" -}}
|
||||
{{- if .Values.enterprise -}}
|
||||
{{- .Values.enterpriseImage -}}
|
||||
{{- else -}}
|
||||
{{- .Values.image -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- define "teleport-kube-agent.image" -}}
|
||||
{{ include "teleport-kube-agent.baseImage" . }}:{{ include "teleport-kube-agent.version" . }}
|
||||
{{- end -}}
|
||||
Reference in New Issue
Block a user