apiVersion: v1
kind: PersistentVolumeClaim
metadata:
  name: task-pv-claim
spec:
  storageClassName: yrcloudfile-sc
  accessModes:
    - ReadWriteOnce
  resources:
    requests:
      storage: 100Gi
---
apiVersion: apps/v1
kind: Deployment
metadata:
  name: yrfs-test-pod
spec:
  selector:
    matchLabels:
      app: yrfs-test-pod
  replicas: 1
  template:
    metadata:
      labels:
        app: yrfs-test-pod
    spec:
      volumes:
        - name: yrfs
          persistentVolumeClaim:
            claimName: task-pv-claim
      containers:
      - image: docker.io/centos:7.4.1708
        command:
          - sh
          - -c
          - 'tail -f /dev/null'
        imagePullPolicy: IfNotPresent
        name: busybox
        volumeMounts:
        # name must match the volume name below
        - name: yrfs
          mountPath: "/mnt"

