WARNING: This driver is in ALPHA currently. Do NOT use this driver in a production environment in its current state.
This driver allows Kubernetes to use azure-storage-fuse, csi plugin name: blobfuse.csi.azure.com
Status: Aplha
| Blobfuse CSI Driver Version | Image | v1.0.0 |
|---|---|---|
| v0.1.0-alpha | mcr.microsoft.com/k8s/csi/blobfuse-csi:v0.1.0-alpha | yes |
| master branch | mcr.microsoft.com/k8s/csi/blobfuse-csi:latest | yes |
| Blobfuse CSI Driver\Kubernetes Version | 1.13+ |
|---|---|
| v0.1.0-alpha | yes |
| master branch | yes |
Please refer to blobfuse.csi.azure.com driver parameters
storage class
blobfuse.csi.azure.comparameters are compatible with built-in blobfuse plugin
- The driver initialization depends on a Cloud provider config file, usually it's
/etc/kubernetes/azure.jsonon all k8s nodes deployed by AKS or aks-engine, here is an azure.json example
Please refer to install blobfuse csi driver
create a pod with blobfuse mount on linux
- Create a blobfuse CSI storage class
kubectl create -f https://raw.githubusercontent.com/csi-driver/blobfuse-csi-driver/master/deploy/example/storageclass-blobfuse-csi.yaml- Create a blobfuse CSI PVC
kubectl create -f https://raw.githubusercontent.com/csi-driver/blobfuse-csi-driver/master/deploy/example/pvc-blobfuse-csi.yamlmake sure the existing credentials in k8s cluster(e.g. service principal, msi) could access the specified storage account
- Download a blobfuse CSI storage class, edit
resourceGroup,storageAccount,containerNamein storage class
wget https://raw.githubusercontent.com/csi-driver/blobfuse-csi-driver/master/deploy/example/storageclass-blobfuse-csi-existing-container.yaml
vi storageclass-blobfuse-csi-existing-container.yaml
kubectl create -f storageclass-blobfuse-csi-existing-container.yaml- Create a blobfuse CSI PVC
kubectl create -f https://raw.githubusercontent.com/csi-driver/blobfuse-csi-driver/master/deploy/example/pvc-blobfuse-csi.yaml- Use
kubectl create secretto createazure-secretwith existing storage account name and key
kubectl create secret generic azure-secret --from-literal accountname=NAME --from-literal accountkey="KEY" --type=Opaque
- Create a blobfuse CSI PV, download
pv-blobfuse-csi.yamlfile and editcontainerNameinvolumeAttributes
wget https://raw.githubusercontent.com/csi-driver/blobfuse-csi-driver/master/deploy/example/pv-blobfuse-csi.yaml
vi pv-blobfuse-csi.yaml
kubectl create -f pv-blobfuse-csi.yaml- Create a blobfuse CSI PVC which would be bound to the above PV
kubectl create -f https://raw.githubusercontent.com/csi-driver/blobfuse-csi-driver/master/deploy/example/pvc-blobfuse-csi-static.yaml
make sure pvc is created and in
Boundstatus
watch kubectl describe pvc pvc-blobfuse
- create a pod with blobfuse CSI PVC
kubectl create -f https://raw.githubusercontent.com/csi-driver/blobfuse-csi-driver/master/deploy/example/nginx-pod-blobfuse.yaml
- watch the status of pod until its Status changed from
PendingtoRunningand then enter the pod container
$ watch kubectl describe po nginx-blobfuse
$ kubectl exec -it nginx-blobfuse -- bash
Filesystem Size Used Avail Use% Mounted on
...
blobfuse 30G 8.9G 21G 31% /mnt/blobfuse
/dev/sda1 30G 8.9G 21G 31% /etc/hosts
...In the above example, there is a /mnt/blobfuse directory mounted as dysk filesystem.
Please refer to development guide