新增learn-kubernetes(https://github.com/yyong-brs/learn-kubernetes)相关文件
This commit is contained in:
@@ -0,0 +1,30 @@
|
||||
apiVersion: batch/v1
|
||||
kind: Job
|
||||
metadata:
|
||||
name: pi-job-random
|
||||
labels:
|
||||
kiamol: ch08
|
||||
spec:
|
||||
completions: 3
|
||||
parallelism: 3
|
||||
template:
|
||||
spec:
|
||||
initContainers:
|
||||
- name: init-dp
|
||||
image: kiamol/ch03-sleep
|
||||
command: ['sh', '-c', 'echo $RANDOM > /init/dp']
|
||||
volumeMounts:
|
||||
- name: init
|
||||
mountPath: /init
|
||||
containers:
|
||||
- name: pi
|
||||
image: kiamol/ch05-pi
|
||||
command: ['sh', '-c', 'dotnet Pi.Web.dll -m console -dp $(cat /init/dp)']
|
||||
volumeMounts:
|
||||
- name: init
|
||||
mountPath: /init
|
||||
readOnly: true
|
||||
restartPolicy: Never
|
||||
volumes:
|
||||
- name: init
|
||||
emptyDir: {}
|
||||
Reference in New Issue
Block a user