apiVersion: v1 
kind: Pod 
metadata:
    name: web 
    labels:  
        app: nginx
spec: # Описание Pod
  containers:
  - name: nginx 
    image: mikhailmar/kuberintro_nginx:1.2
    imagePullPolicy: Always
    readinessProbe:
      httpGet:
        path: /index.html
        port: 8000
    livenessProbe:
      tcpSocket:
        port: 8000
    volumeMounts:
    - name: app
      mountPath: /app
  volumes:
  - name: app
    emptyDir: {}
  initContainers:
  - name: init-index
    image: busybox:1.28
    imagePullPolicy: Always
    volumeMounts:
    - name: app
      mountPath: /app

    command: ['sh', '-c', 'wget -O- https://tinyurl.com/otus-k8s-intro  | sh']

