mirror of
https://github.com/prowler-cloud/prowler.git
synced 2026-10-04 02:04:06 +00:00
Co-authored-by: Janderik Marins <janderik@email.com> Co-authored-by: Daniel Barranquero <danielbo2001@gmail.com>
30 lines
998 B
YAML
30 lines
998 B
YAML
# https://docs.prowler.com/projects/prowler-open-source/en/latest/tutorials/prowler-app/#step-44-kubernetes-credentials
|
|
apiVersion: rbac.authorization.k8s.io/v1
|
|
kind: ClusterRole
|
|
metadata:
|
|
name: {{ include "prowler.fullname" . }}-api
|
|
labels:
|
|
{{- include "prowler.labels" . | nindent 4 }}
|
|
rules:
|
|
- apiGroups: [""]
|
|
resources: ["pods", "configmaps", "nodes", "namespaces"]
|
|
verbs: ["get", "list", "watch"]
|
|
- apiGroups: ["rbac.authorization.k8s.io"]
|
|
resources: ["clusterrolebindings", "rolebindings", "clusterroles", "roles"]
|
|
verbs: ["get", "list", "watch"]
|
|
---
|
|
apiVersion: rbac.authorization.k8s.io/v1
|
|
kind: ClusterRoleBinding
|
|
metadata:
|
|
name: {{ include "prowler.fullname" . }}-api
|
|
labels:
|
|
{{- include "prowler.labels" . | nindent 4 }}
|
|
roleRef:
|
|
apiGroup: rbac.authorization.k8s.io
|
|
kind: ClusterRole
|
|
name: {{ include "prowler.fullname" . }}-api
|
|
subjects:
|
|
- kind: ServiceAccount
|
|
name: {{ include "prowler.api.serviceAccountName" . }}
|
|
namespace: {{ .Release.Namespace }}
|