2018-01-31 09:31:45 +08:00
|
|
|
apiVersion: v1
|
|
|
|
kind: ServiceAccount
|
|
|
|
metadata:
|
|
|
|
name: admin-user
|
|
|
|
namespace: kube-system
|
|
|
|
|
|
|
|
---
|
|
|
|
apiVersion: rbac.authorization.k8s.io/v1
|
|
|
|
kind: ClusterRoleBinding
|
|
|
|
metadata:
|
|
|
|
name: admin-user
|
|
|
|
roleRef:
|
|
|
|
apiGroup: rbac.authorization.k8s.io
|
|
|
|
kind: ClusterRole
|
|
|
|
name: cluster-admin
|
|
|
|
subjects:
|
|
|
|
- kind: ServiceAccount
|
|
|
|
name: admin-user
|
|
|
|
namespace: kube-system
|
|
|
|
|
2022-06-07 20:39:15 +08:00
|
|
|
---
|
|
|
|
apiVersion: v1
|
|
|
|
kind: Secret
|
|
|
|
type: kubernetes.io/service-account-token
|
|
|
|
metadata:
|
|
|
|
name: admin-user
|
|
|
|
namespace: kube-system
|
|
|
|
annotations:
|
|
|
|
kubernetes.io/service-account.name: "admin-user"
|