oc-k8s/opencloud/charts/nats/files/stateful-set/reloader-container.yaml

28 lines
651 B
YAML
Raw Permalink Normal View History

2024-11-29 10:30:47 +01:00
name: reloader
{{ include "nats.image" (merge (pick $.Values "global") .Values.reloader.image) }}
{{- with .Values.reloader.env }}
env:
{{- include "nats.env" . }}
{{- end }}
args:
- -pid
- /var/run/nats/nats.pid
- -config
- /etc/nats-config/nats.conf
{{ include "nats.reloaderConfig" (dict "config" .config "dir" "/etc/nats-config") }}
volumeMounts:
- name: pid
mountPath: /var/run/nats
{{- range $mnt := .natsVolumeMounts }}
{{- $found := false }}
{{- range $.Values.reloader.natsVolumeMountPrefixes }}
{{- if and (not $found) (hasPrefix . $mnt.mountPath) }}
{{- $found = true }}
- {{ toYaml $mnt | nindent 2}}
{{- end }}
{{- end }}
{{- end }}