- available driver version:
v0.7.0
or above
This driver also supports reading the cloud config from Kubernetes secrets. The secret is a serialized version of azure.json
file with key cloud-config. The secret should be put in kube-system
namespace and its name should be azure-cloud-provider
.
- create
azure.json
file and fill in all necessary fields, refer to Cloud provider config, and here is an example - serialize
azure.json
by following command:
cat azure.json | base64 | awk '{printf $0}'; echo
- create a secret file(
azure-cloud-provider.yaml
) with following values and fill incloud-config
value produced in step#2
apiVersion: v1
data:
cloud-config: [fill-in-here]
kind: Secret
metadata:
name: azure-cloud-provider
namespace: kube-system
type: Opaque
- Create a
azure-cloud-provider
secret in k8s cluster
kubectl create -f azure-cloud-provider.yaml
- available driver version:
v1.5.0
or above - set
cloudConfigSecretName
,cloudConfigSecretNamesapce
in driver deployment, follow helm chart guide
- name: azuredisk
...
args:
...
- "--cloud-config-secret-name={{cloudConfigSecretName}}"
- "--cloud-config-secret-namespace={{cloudConfigSecretNamespace}}"