minecraft-servers/active/weather/templates/cronjob.yaml
2024-02-13 19:47:14 -06:00

27 lines
794 B
YAML

apiVersion: batch/v1
kind: CronJob
metadata:
name: {{ .Release.Name }}-weather-cronjob
spec:
schedule: "{{ .Values.schedule }}"
jobTemplate:
spec:
template:
metadata:
labels:
app: weather-job
spec:
containers:
- name: weather-container
image: {{ .Values.container.image }}
command: ["sh", "-c", "{{ .Values.container.command }}"]
volumeMounts:
- name: logs-volume
mountPath: /logs
subPath: logs
restartPolicy: {{ .Values.restartPolicy }}
volumes:
- name: logs-volume
persistentVolumeClaim:
claimName: {{ .Values.volume.claimName }}
subPath: logs