feat: add local-storage-class configuration
- Introduce a new StorageClass named `local-data` - Set provisioner to `rancher.io/local-path` - Define parameters including `nodePath` and `pathPattern` - Modify existing StorageClass from `local-data` to `local-zgus1` and include `nodeSelector` This commit sets up a local storage class to be used within the Kubernetes environment, enabling better management of local volumes. The new configuration allows for efficient volume binding based on specific node requirements.
This commit is contained in:
parent
db69791a4d
commit
f8e0654b8f
@ -1,3 +1,15 @@
|
||||
---
|
||||
apiVersion: storage.k8s.io/v1
|
||||
kind: StorageClass
|
||||
metadata:
|
||||
name: local-data
|
||||
provisioner: rancher.io/local-path
|
||||
volumeBindingMode: WaitForFirstConsumer
|
||||
reclaimPolicy: Delete
|
||||
parameters:
|
||||
nodePath: /data/local-csi
|
||||
pathPattern: "{{ .PVC.Namespace }}/{{ .PVC.Name }}"
|
||||
---
|
||||
apiVersion: storage.k8s.io/v1
|
||||
kind: StorageClass
|
||||
metadata:
|
||||
@ -85,11 +97,12 @@ parameters:
|
||||
apiVersion: storage.k8s.io/v1
|
||||
kind: StorageClass
|
||||
metadata:
|
||||
name: local-data
|
||||
name: local-zgus1
|
||||
provisioner: rancher.io/local-path
|
||||
volumeBindingMode: WaitForFirstConsumer
|
||||
reclaimPolicy: Delete
|
||||
parameters:
|
||||
nodeSelector: "kubernetes.io/hostname=zgocloud-us1"
|
||||
nodePath: /data/local-csi
|
||||
pathPattern: "{{ .PVC.Namespace }}/{{ .PVC.Name }}"
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user