kubernetes dashboard 只读权限

作者: admin 分类: kubernetes 发布时间: 2018-09-05 17:35 ė 6 没有评论

kubernetes dashboard access only read

---
kind: ClusterRole
apiVersion: rbac.authorization.k8s.io/v1
metadata:
  name: kubernetes-dashboard-read
rules:
- apiGroups: [""]
  resources: ["pods","pods/log"]
  verbs: ["get", "list","watch"]
- apiGroups: [""]
  resources: ["namespaces"]
  verbs: ["get", "list","watch"]

 
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRoleBinding
metadata:
  name: kubernetes-dashboard-read
  labels:
    k8s-app: kubernetes-dashboard
roleRef:
  apiGroup: rbac.authorization.k8s.io
  kind: ClusterRole
  name: kubernetes-dashboard-read
subjects:
- kind: ServiceAccount
  name: kubernetes-dashboard-read
  namespace: kube-system

---
apiVersion: v1
kind: ServiceAccount
metadata:
  labels:
    k8s-app: kubernetes-dashboard
  name: kubernetes-dashboard-read
  namespace: kube-system

首先允许我做个广告,如果你需要购买新疆阿克苏冰糖心苹果/新疆库尔勒香梨,我们自己家种的,一件发货,全国包邮,比超市便宜,坏了给赔、从库尔勒铁门关和阿克苏红旗坡发货,有需要扫码下方我的二维码

本文出自 小Q,转载时请注明出处及相应链接。

本文永久链接: http://www.linuxqq.com/archives/1925.html

0
更多
Ɣ回顶部