Add init container documentation

This commit is contained in:
Clayton Coleman
2016-06-16 17:05:50 -04:00
parent ce6bf3d9c2
commit 47d7b0968b
2 changed files with 51 additions and 0 deletions
@@ -0,0 +1,31 @@
apiVersion: v1
kind: Pod
metadata:
name: nginx
annotations:
pod.alpha.kubernetes.io/init-containers: '[
{
"name": "install",
"image": "busybox",
"command": ["wget", "-O", "/work-dir/index.html", "http://kubernetes.io/index.html"],
"volumeMounts": [
{
"name": "workdir",
"mountPath": "/work-dir"
}
]
}
]'
spec:
containers:
- name: nginx
image: nginx
ports:
- containerPort: 80
volumeMounts:
- name: workdir
mountPath: /usr/share/nginx/html
dnsPolicy: Default
volumes:
- name: workdir
emptyDir: {}