Update RBAC in Azure examples to include csinodes permission #2484
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR fixes the Azure examples to include csinodes permission - same as what #2404 did for AWS. The issued faced is as follows:
Info
Component: cluster-autoscaler
Version: v1.16.1
Problem
Upon deploying cluster-autoscaler in Azure, I started receiving these errors every second:
E1025 08:23:39.529366 1 reflector.go:123] k8s.io/client-go/informers/factory.go:134: Failed to list *v1beta1.CSINode: csinodes.storage.k8s.io is forbidden: User "system:serviceaccount:kube-system:cluster-autoscaler" cannot list resource "csinodes" in API group "storage.k8s.io" at the cluster scope
Solution
Include
csinodes
in the list of resources under apiGroupstorage.k8s.io
of ClusterRolecluster-autoscaler
:PR #2404 fixed the examples only for AWS, while the issue exists for Azure (and likely other providers as well). This one fixes for Azure, and has been tested on it.