apiVersion: apps/v1
kind: ReplicaSet
metadata:
  name: mynapp-rs-nfs
spec:
  replicas: 2
  selector:
    matchLabels:
      app: mynapp-rs-nfs
  template:
    metadata:
      labels:
        app: mynapp-rs-nfs
    spec:
      containers:
      - name: mynapp
        image: nginx
        volumeMounts:
        - name: nfs-share
          mountPath: /usr/share/nginx/html
        ports:
        - containerPort: 80
      volumes:
      - name: nfs-share
        persistentVolumeClaim:
          claimName: mynapp-pvc-nfs
