Open MagicalBomb opened 2 years ago
I had created a clusterRole with following rules. After that I created service account, clusterRoleBinding, kubeconfig.yaml manually.
# ClusterRole.yaml rules: - verbs: - get - list - watch apiGroups: - '' resources: - pods - services - namespaces - nodes - services/proxy - nodes/proxy - nodes/metrics - pods/proxy - verbs: - create - get - update - list - delete - watch - patch apiGroups: - apps resources: - deployment - verbs: - create - get - list - watch apiGroups: - rbac.authorization.k8s.io resources: - clusterroles
# kubeconfig.yaml apiVersion: v1 clusters: - cluster: certificate-authority-data: xxxx server: https://xxx:xxx name: kubernetes contexts: - context: cluster: kubernetes user: adam name: kubernetes-test@kubernetes current-context: kubernetes-test@kubernetes kind: Config users: - name: adam user: token: xxxx
I added the kubeconfig.yaml to Lens and log in my cluster successfully, but it can't fetch metrics. I am wondering if there are some mistake I made and I really don't want login with default amin user. Could someone help, thx!
Does https://github.com/lensapp/lens/issues/3698 help?
This worked for me for Lens built-in metrics on the LDK cluster. Note that create is required for services/proxy, not sure why.
create
services/proxy
I had created a clusterRole with following rules. After that I created service account, clusterRoleBinding, kubeconfig.yaml manually.
I added the kubeconfig.yaml to Lens and log in my cluster successfully, but it can't fetch metrics. I am wondering if there are some mistake I made and I really don't want login with default amin user. Could someone help, thx!