Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug with k3k-node-proxy ClusterRole #203

Open
enrichman opened this issue Jan 22, 2025 · 0 comments
Open

Bug with k3k-node-proxy ClusterRole #203

enrichman opened this issue Jan 22, 2025 · 0 comments
Labels
bug Something isn't working controller priority/0 high priority

Comments

@enrichman
Copy link
Collaborator

The k3k-node-proxy ClusterRole is needed from the Kubelet to list the host nodes, and fetch some metrics.

The chart is currently building the name with the release installation. But the kubelet is expecting a fixed name for the ClusterRoleBinding, such as k3k-node-proxy. This means that if installing the chart with a different name than k3k will result in some permissions error.

kind: ClusterRoleBinding
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: {{ include "k3k.fullname" . }}-node-proxy
roleRef:
kind: ClusterRole
name: {{ include "k3k.fullname" . }}-node-proxy
apiGroup: rbac.authorization.k8s.io

clusterRoleBinding := &rbacv1.ClusterRoleBinding{}
if err := c.Client.Get(ctx, types.NamespacedName{Name: "k3k-node-proxy"}, clusterRoleBinding); err != nil {
return fmt.Errorf("failed to get or find k3k-node-proxy ClusterRoleBinding: %w", err)
}

@enrichman enrichman added bug Something isn't working controller labels Jan 22, 2025
@jp-gouin jp-gouin added the priority/0 high priority label Jan 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working controller priority/0 high priority
Projects
None yet
Development

No branches or pull requests

2 participants