clearml-helm-charts/charts/clearml/templates/apps-rbac.yaml
Valeriano Manassero 67d4b5b95d
Enterprise apps sa (#134)
* Changed: don't use cluster wide access

* Changed: bump version
2023-01-20 10:24:34 +01:00

34 lines
862 B
YAML

{{- if .Values.enterpriseFeatures.enabled }}
{{- if .Values.enterpriseFeatures.clearmlApplications.enabled }}
apiVersion: v1
kind: ServiceAccount
metadata:
name: "clearml-apps-sa"
namespace: {{ .Release.Namespace }}
---
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
name: {{ include "clearmlApplications.referenceName" . }}-kpa
rules:
- apiGroups:
- ""
resources:
- pods
verbs: ["get", "list", "watch", "create", "patch", "delete"]
---
apiVersion: rbac.authorization.k8s.io/v1
kind: RoleBinding
metadata:
name: {{ include "clearmlApplications.referenceName" . }}-kpa
subjects:
- kind: ServiceAccount
name: "clearml-apps-sa"
namespace: {{ .Release.Namespace }}
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: Role
name: {{ include "clearmlApplications.referenceName" . }}-kpa
{{- end }}
{{- end }}