rancher / local-path-provisioner

Dynamically provisioning persistent local storage with Kubernetes
Apache License 2.0
2.07k stars 439 forks source link

StorageClass annotations defaultVolumeType not work #390

Closed lanss315425 closed 1 month ago

lanss315425 commented 3 months ago

hi ,I am not working properly using the Storage Class annotations defaultVolume Type,Normally, there is a volumeType: local in the annotations of PVC. The following image shows my Storage Class.

image

this is my pvc :

kind: PersistentVolumeClaim
apiVersion: v1
metadata:
  name: nginx-test-pvc
spec:
  storageClassName: local-path
  accessModes:
    - ReadWriteOnce
  resources:
    requests:
      storage: 10Gi

kubectl describe pvc nginx-test-pvc:

image image
derekbit commented 3 months ago

Can you provide more information such as the steps to reproduce and local-path provisioner version?

lanss315425 commented 3 months ago

hi @derekbit This is the version I am using. https://raw.githubusercontent.com/rancher/local-path-provisioner/v0.0.26/deploy/local-path-storage.yaml

derekbit commented 3 months ago

@lanss315425 What's your Kubernetes version?

lanss315425 commented 3 months ago

@derekbit Kubernetes v1.26.13

derekbit commented 3 months ago

@lanss315425 Wait. I don't think it is wrong. What's your expectation?

lanss315425 commented 3 months ago

I expect that when the annotation for PersistentvolumeClaim is empty, the annotation for StorageClass will be applied to all volumes that use it

lanss315425 commented 3 months ago

like this

image
github-actions[bot] commented 1 month ago

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.

github-actions[bot] commented 1 month ago

This issue was closed because it has been stalled for 5 days with no activity.