Reputation: 2569
I have a kubernetes user(below is the kubeconfig).
users:
- name: [email protected]
user:
auth-provider:
config:
client-id: XXX
client-secret: XXX
id-token: XXX
refresh-token:
When making GET request to the kubernetes API, I am getting the below error.
GET request - https://sourcegraph.com/github.com/vapor-ware/ksync/-/blob/pkg/ksync/doctor/kubernetes.go#L78
err= forbidden: User "[email protected]" cannot get path "/"
What is the exact role i need to create to give access to the path "/"
Upvotes: 1
Views: 99
Reputation: 2569
Only a cluster admin can access "/"
Here is the role for it.
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
name: cluster-admin
rules:
- apiGroups:
- '*'
resources:
- '*'
verbs:
- '*'
- nonResourceURLs:
- '*'
verbs:
- '*
Upvotes: 1