42 lines
1.1 KiB
YAML
42 lines
1.1 KiB
YAML
{{- include "bjw-s.common.loader.init" . }}
|
|
|
|
{{- define "cloudflared.hardcodedValues" -}}
|
|
{{ if not .Values.global.nameOverride }}
|
|
global:
|
|
nameOverride: {{ .Values.name }}
|
|
{{ end }}
|
|
controllers:
|
|
main:
|
|
type: deployment
|
|
strategy: Recreate
|
|
containers:
|
|
main:
|
|
image:
|
|
repository: {{ .Values.image.repository }}
|
|
tag: {{ .Values.image.tag }}
|
|
pullPolicy: {{ .Values.image.pullPolicy }}
|
|
args:
|
|
- tunnel
|
|
- --protocol
|
|
- http2
|
|
- --no-autoupdate
|
|
- run
|
|
- --token
|
|
- $(CF_MANAGED_TUNNEL_TOKEN)
|
|
env:
|
|
- name: CF_MANAGED_TUNNEL_TOKEN
|
|
valueFrom:
|
|
secretKeyRef:
|
|
name: {{ .Values.existingSecretName }}
|
|
key: {{ .Values.existingSecretKey }}
|
|
resources:
|
|
{{- with .Values.resources }}
|
|
resources:
|
|
{{- toYaml . | nindent 10 }}
|
|
{{ end }}
|
|
{{- end -}}
|
|
{{- $_ := mergeOverwrite .Values (include "cloudflared.hardcodedValues" . | fromYaml) -}}
|
|
|
|
{{/* Render the templates */}}
|
|
{{ include "bjw-s.common.loader.generate" . }}
|