more policy
This commit is contained in:
parent
9cfab5dca5
commit
50c12bcf8f
1 changed files with 14 additions and 1 deletions
|
|
@ -5,8 +5,14 @@ metadata:
|
||||||
name: {{ .Release.Name }}-cronjob
|
name: {{ .Release.Name }}-cronjob
|
||||||
spec:
|
spec:
|
||||||
schedule: "{{ .Values.schedule }}"
|
schedule: "{{ .Values.schedule }}"
|
||||||
|
startingDeadlineSeconds: 200
|
||||||
|
concurrencyPolicy: Forbid
|
||||||
|
successfulJobsHistoryLimit: 1
|
||||||
|
failedJobsHistoryLimit: 1
|
||||||
jobTemplate:
|
jobTemplate:
|
||||||
spec:
|
spec:
|
||||||
|
activeDeadlineSeconds: 180
|
||||||
|
ttlSecondsAfterFinished: 100
|
||||||
template:
|
template:
|
||||||
spec:
|
spec:
|
||||||
containers:
|
containers:
|
||||||
|
|
@ -21,6 +27,13 @@ spec:
|
||||||
echo "Fetching temperature" && \
|
echo "Fetching temperature" && \
|
||||||
python /scripts/temperature_fetcher.py && \
|
python /scripts/temperature_fetcher.py && \
|
||||||
sleep 300
|
sleep 300
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
cpu: "100m"
|
||||||
|
memory: "128Mi"
|
||||||
|
limits:
|
||||||
|
cpu: "200m"
|
||||||
|
memory: "256Mi"
|
||||||
env:
|
env:
|
||||||
- name: CITY
|
- name: CITY
|
||||||
value: "{{ .Values.city }}"
|
value: "{{ .Values.city }}"
|
||||||
|
|
@ -33,7 +46,7 @@ spec:
|
||||||
mountPath: "{{ .Values.mountPath }}"
|
mountPath: "{{ .Values.mountPath }}"
|
||||||
- name: script-volume
|
- name: script-volume
|
||||||
mountPath: /scripts
|
mountPath: /scripts
|
||||||
restartPolicy: OnFailure
|
restartPolicy: Never
|
||||||
volumes:
|
volumes:
|
||||||
- name: sqlite-data
|
- name: sqlite-data
|
||||||
hostPath:
|
hostPath:
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue