
---
apiVersion: apps/v1
kind: Deployment
metadata:
  name: nginx-deployment01
  labels:
    app: nginx
  namespace: test-01
spec:
  replicas: 0
  selector:
    matchLabels:
      app: nginx
  template:
    metadata:
      labels:
        app: nginx
    spec:
      containers:
      - name: nginx
        image: nginx:1.17
        ports:
        - containerPort: 80
        livenessProbe:
          httpGet:
              port: 80
        volumeMounts:
          - mountPath:  /usr/share/nginx/html/
            name: data
      volumes:
      - name: data
        persistentVolumeClaim:
          claimName: pvc02
