pod的存储-pv-pvc-storageclass

动态存储: provisioner
https://github.com/kubernetes-retired/external-storage.git

apiVersion: apps/v1
kind: DaemonSet
metadata:
  name: busybox-daemonset
  labels:
    app: busybox
spec:
  selector:
    matchLabels:
      app: busybox
  template:
    metadata:
      labels:
        app: busybox
    spec:
      containers:
      - name: busybox
        image: busybox:1.28.4
        command:
          - sleep
          - "36000"
        volumeMounts:
        - mountPath: /cache
          name: cache-volume
      volumes:
      - name: cache-volume
        emptyDir: {}
      restartPolicy: Always

hostpath

posted @ 2021-08-12 16:28  lavida2000  阅读(68)  评论(0)    收藏  举报