hinzugefügt eine CronJob Definition mit einer Ausgabe
This commit is contained in:
parent
f31ca9840f
commit
a3aa5dd4d0
24
Kubernetes/LFS258/cron-job-with-output.yaml
Normal file
24
Kubernetes/LFS258/cron-job-with-output.yaml
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
apiVersion: batch/v1
|
||||||
|
kind: CronJob
|
||||||
|
metadata:
|
||||||
|
name: date-job
|
||||||
|
spec:
|
||||||
|
schedule: "*/1 * * * *"
|
||||||
|
jobTemplate:
|
||||||
|
metadata:
|
||||||
|
name: cron-job-hello
|
||||||
|
spec:
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
name: hello
|
||||||
|
spec:
|
||||||
|
containers:
|
||||||
|
- name: hello
|
||||||
|
image: busybox
|
||||||
|
args:
|
||||||
|
- /bin/bash
|
||||||
|
- -c
|
||||||
|
- date; echo "hello from kubernetes cluster"
|
||||||
|
restartPolicy: OnFailure
|
||||||
|
|
||||||
|
|
||||||
Loading…
x
Reference in New Issue
Block a user