Created
September 17, 2020 11:47
-
-
Save prohazko2/1ce9926c30a786fabb6899c8e63f935e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
apiVersion: v1 | |
kind: ServiceAccount | |
metadata: | |
name: monitoring | |
namespace: kube-system | |
secrets: | |
- name: monitoring-secret-token | |
--- | |
apiVersion: v1 | |
kind: Secret | |
metadata: | |
name: monitoring-secret-token | |
namespace: kube-system | |
annotations: | |
kubernetes.io/service-account.name: monitoring | |
type: kubernetes.io/service-account-token | |
--- | |
apiVersion: rbac.authorization.k8s.io/v1 | |
kind: ClusterRole | |
metadata: | |
name: monitoring-clusterrole | |
namespace: kube-system | |
rules: | |
- apiGroups: [""] | |
resources: | |
- nodes | |
- nodes/proxy | |
- pods | |
verbs: ["get", "list"] | |
- nonResourceURLs: ["/metrics", "/metrics/*", "/healthz", "/healthz/*"] | |
verbs: ["get"] | |
--- | |
apiVersion: rbac.authorization.k8s.io/v1beta1 | |
kind: ClusterRoleBinding | |
metadata: | |
name: monitoring-clusterrole-binding | |
namespace: kube-system | |
roleRef: | |
kind: ClusterRole | |
name: monitoring-clusterrole | |
apiGroup: rbac.authorization.k8s.io | |
subjects: | |
- kind: ServiceAccount | |
name: monitoring | |
namespace: kube-system |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment