mirror of
https://github.com/truenas/charts.git
synced 2026-04-28 12:32:55 +08:00
64 lines
1.9 KiB
Smarty
64 lines
1.9 KiB
Smarty
{{- define "listmonk.workload" -}}
|
|
workload:
|
|
listmonk:
|
|
enabled: true
|
|
primary: true
|
|
type: Deployment
|
|
podSpec:
|
|
hostNetwork: {{ .Values.listmonkNetwork.hostNetwork }}
|
|
containers:
|
|
listmonk:
|
|
enabled: true
|
|
primary: true
|
|
imageSelector: image
|
|
securityContext:
|
|
runAsUser: {{ .Values.listmonkRunAs.user }}
|
|
runAsGroup: {{ .Values.listmonkRunAs.group }}
|
|
envFrom:
|
|
- secretRef:
|
|
name: listmonk-creds
|
|
{{ with .Values.listmonkConfig.additionalEnvs }}
|
|
envList:
|
|
{{ range $env := . }}
|
|
- name: {{ $env.name }}
|
|
value: {{ $env.value }}
|
|
{{ end }}
|
|
{{ end }}
|
|
probes:
|
|
liveness:
|
|
enabled: true
|
|
type: http
|
|
port: {{ .Values.listmonkNetwork.webPort }}
|
|
path: /health
|
|
readiness:
|
|
enabled: true
|
|
type: http
|
|
port: {{ .Values.listmonkNetwork.webPort }}
|
|
path: /health
|
|
startup:
|
|
enabled: true
|
|
type: http
|
|
port: {{ .Values.listmonkNetwork.webPort }}
|
|
path: /health
|
|
initContainers:
|
|
{{- include "ix.v1.common.app.postgresWait" (dict "name" "01-postgres-wait"
|
|
"secretName" "postgres-creds") | nindent 8 }}
|
|
02-db:
|
|
enabled: true
|
|
type: init
|
|
imageSelector: image
|
|
securityContext:
|
|
runAsUser: {{ .Values.listmonkRunAs.user }}
|
|
runAsGroup: {{ .Values.listmonkRunAs.group }}
|
|
envFrom:
|
|
- secretRef:
|
|
name: listmonk-creds
|
|
command:
|
|
- /bin/sh
|
|
args:
|
|
- -c
|
|
- |
|
|
/listmonk/listmonk --install --idempotent --yes
|
|
/listmonk/listmonk --upgrade --yes
|
|
{{- end -}}
|