标签:start rom xms dep always ora main odi 监控
apiVersion: apps/v1beta2
kind: ReplicaSet
metadata:
name: kubia
spec:
replicas: 3
selector:
matchLables:
app: kubia
template:
metadata:
lables:
app:kubia
spec:
containers:
- name:kubia
image: luska/kubia
selector:
matchExpressions:
- key: app
operator: In
values:
- kubia
apiVersion: apps/v1beta2
kind: DaemonSet
metadata:
name: ssd-monitor
spec:
selector:
matchLables:
app: ssd-monitor
template:
metadata:
lables:
app: ssd-monitor
spec:
nodeSelector:
disk: ssd
containers:
- name: main
image: luksa/ssd-monitor
apiVersion: batch/v1
kind: Job
metadata:
name: batch-job
spec:
template:
metadata:
lables:
app: batch-job
spec:
restartPolicy: onFailure Job不能使用Always为默认的重启策略
containers:
- name: main
image: luksa/batch-job
apiVersion: batch/v1
kind: Job
metadata:
name: batch-job
spec:
completions: 5
template:
... ...
apiVersion: batch/v1
kind: Job
metadata:
name: batch-job
spec:
completions: 5 共计运行5次
parallelism: 2 可以并行2个
template:
... ...
apiVersion: batch/v1beta1
kind: CronJob
metadata:
name: batch-job-every-fifteen-minutes
spec:
schedule: "0,15,30,45 * * * *" 每15分钟执行一次并且在0,15,30,45
JobTemplate:
spec:
template:
matedata:
lables:
app: periodic-batch-job
spec:
restartPolicy: OnFailure
containers:
- name: main
image: luksa/batch-job
apiVersion: batch/v1beta1
kind: CronJob
metadata:
name: batch-job-every-fifteen-minutes
spec:
schedule: "0,15,30,45 * * * *" 每15分钟执行一次并且在0,15,30,45
startingDeadlineSeconds: 15
JobTemplate:
标签:start rom xms dep always ora main odi 监控
原文地址:https://www.cnblogs.com/zhming26/p/11719406.html