@@ -77,7 +77,10 @@ setup() {
7777 fi
7878 echo " Using cluster template: ${CLUSTER_TEMPLATE} "
7979
80- export CLUSTER_NAME=" ${CLUSTER_NAME:- capz-$(head / dev/ urandom | LC_ALL=C tr -dc a-z0-9 | head -c 6 ; echo ' ' )} "
80+ export CLUSTER_NAME=" ${CLUSTER_NAME:- capz-$(
81+ head / dev/ urandom | LC_ALL=C tr -dc a-z0-9 | head -c 6
82+ echo ' '
83+ )} "
8184 export AZURE_RESOURCE_GROUP=" ${CLUSTER_NAME} "
8285 export AZURE_LOCATION=" ${AZURE_LOCATION:- $(capz:: util:: get_random_region)} "
8386 echo " Using AZURE_LOCATION: ${AZURE_LOCATION} "
@@ -144,12 +147,12 @@ wait_for_nodes() {
144147copy_secret () {
145148 # point at the management cluster
146149 unset KUBECONFIG
147- " ${KUBECTL} " get secret " ${CLUSTER_NAME} -control-plane-azure-json" -o jsonpath=' {.data.control-plane-azure\.json}' | base64 --decode > azure_json
148-
150+ " ${KUBECTL} " get secret " ${CLUSTER_NAME} -control-plane-azure-json" -o jsonpath=' {.data.control-plane-azure\.json}' | base64 --decode > azure_json
151+
149152 # set KUBECONFIG back to the workload cluster
150153 export KUBECONFIG=" ${KUBECONFIG:- ${PWD} / kubeconfig} "
151154 " ${KUBECTL} " create secret generic " ${CONFIG_SECRET_NAME} " -n kube-system \
152- --from-file=cloud-config=azure_json
155+ --from-file=cloud-config=azure_json
153156 rm azure_json
154157}
155158
@@ -208,19 +211,21 @@ if [[ -n "${TEST_CCM:-}" ]]; then
208211 copy_secret
209212 fi
210213
214+ export CCM_LOG_VERBOSITY=" ${CCM_LOG_VERBOSITY:- 4} "
211215 echo " Installing cloud-provider-azure components via helm"
212216 " ${HELM} " install --repo https://raw.githubusercontent.com/kubernetes-sigs/cloud-provider-azure/master/helm/repo cloud-provider-azure --generate-name \
213- --set infra.clusterName=" ${CLUSTER_NAME} " \
214- --set cloudControllerManager.imageRepository=" ${IMAGE_REGISTRY} " \
215- --set cloudNodeManager.imageRepository=" ${IMAGE_REGISTRY} " \
216- --set cloudControllerManager.imageName=" ${CCM_IMAGE_NAME} " \
217- --set cloudNodeManager.imageName=" ${CNM_IMAGE_NAME} " \
218- --set-string cloudControllerManager.imageTag=" ${IMAGE_TAG} " \
219- --set-string cloudNodeManager.imageTag=" ${IMAGE_TAG} " \
220- --set cloudControllerManager.replicas=" ${CCM_COUNT} " \
221- --set cloudControllerManager.enableDynamicReloading=" ${ENABLE_DYNAMIC_RELOADING} " \
222- --set cloudControllerManager.cloudConfig=" ${CLOUD_CONFIG} " \
223- --set cloudControllerManager.cloudConfigSecretName=" ${CONFIG_SECRET_NAME} "
217+ --set infra.clusterName=" ${CLUSTER_NAME} " \
218+ --set cloudControllerManager.imageRepository=" ${IMAGE_REGISTRY} " \
219+ --set cloudNodeManager.imageRepository=" ${IMAGE_REGISTRY} " \
220+ --set cloudControllerManager.imageName=" ${CCM_IMAGE_NAME} " \
221+ --set cloudNodeManager.imageName=" ${CNM_IMAGE_NAME} " \
222+ --set-string cloudControllerManager.imageTag=" ${IMAGE_TAG} " \
223+ --set-string cloudNodeManager.imageTag=" ${IMAGE_TAG} " \
224+ --set cloudControllerManager.replicas=" ${CCM_COUNT} " \
225+ --set cloudControllerManager.enableDynamicReloading=" ${ENABLE_DYNAMIC_RELOADING} " \
226+ --set cloudControllerManager.cloudConfig=" ${CLOUD_CONFIG} " \
227+ --set cloudControllerManager.cloudConfigSecretName=" ${CONFIG_SECRET_NAME} " \
228+ --set cloudControllerManager.logVerbosity=" ${CCM_LOG_VERBOSITY} "
224229
225230 echo " Waiting for all kube-system pods to be ready"
226231 " ${KUBECTL} " wait --for=condition=Ready pod -n kube-system --all --timeout=10m
0 commit comments