Kubernetes Local PV Provisioner helps you setting up local persistent volumes by looking at the state and creating an empty directory on the filesystem of the correct Kubernetes server if needed.
This tool is made to run in cluster as a DaemonSet with the root file system mounted. For testing purposes it can also run locally with a connection to a Kubernetes cluster, however this is of no use since it can not create the directory on the server.
This repository provides example manifests file you can use to deploy this. These contain a service account and RBAC configuration for the tool to be able to read the Persistent Volumes. As well as a DaemonSet to deploy this on all servers in a cluster.
~ $ cd manifests
~ $ kubectl apply -f rbac.yaml
~ $ kubectl apply -f daemonset.yamlWe also provide a Helm chart in our Charts repository.
~ $ helm repo add srcd https://src-d.github.io/charts/
~ $ helm install srcd/kubernetes-local-pv-provisioner --set image.tag=v1.0.0- envvar:
NODE_NAMEflag:--node-nameThis is the server's hostname it will look for in the PV's NodeSelector - envvar:
ROOTFS_PATHflag:--rootfs-pathThis is the prefix used in the path to locate where the root filesystem is mounted. Default:/rootfs - envvar:
KUBERNETES_CONTEXTflag:--contextIf this is set it will not attempt to load the in-cluster service account but loads the context value out of$HOME/.kube/config
Contributions are more than welcome, if you are interested please take a look to our Contributing Guidelines.
All activities under source{d} projects are governed by the source{d} code of conduct.
Apache License Version 2.0, see LICENSE.