diff --git a/src/templates/flink-k8s-operator/flink-deployment-creator-role.yaml b/src/templates/flink-k8s-operator/flink-deployment-creator-role.yaml new file mode 100644 index 0000000..ce83ac3 --- /dev/null +++ b/src/templates/flink-k8s-operator/flink-deployment-creator-role.yaml @@ -0,0 +1,8 @@ +apiVersion: rbac.authorization.k8s.io/v1 +kind: Role +metadata: + name: flink-deployment-creator +rules: +- apiGroups: ["flink.apache.org"] + resources: ["flinkdeployments"] + verbs: ["create", "delete", "list", "update", "get"] diff --git a/src/templates/flink-k8s-operator/flink-deployment-creator-rolebinding.yaml b/src/templates/flink-k8s-operator/flink-deployment-creator-rolebinding.yaml new file mode 100644 index 0000000..871f2c9 --- /dev/null +++ b/src/templates/flink-k8s-operator/flink-deployment-creator-rolebinding.yaml @@ -0,0 +1,11 @@ +apiVersion: rbac.authorization.k8s.io/v1 +kind: RoleBinding +metadata: + name: flink-deployment-creator-binding +subjects: +- kind: ServiceAccount + name: nussknacker +roleRef: + kind: Role + name: flink-deployment-creator + apiGroup: rbac.authorization.k8s.io \ No newline at end of file diff --git a/src/templates/flink-k8s-operator/flink-service-account-clusterrolebinding.yaml b/src/templates/flink-k8s-operator/flink-service-account-clusterrolebinding.yaml new file mode 100644 index 0000000..7112fda --- /dev/null +++ b/src/templates/flink-k8s-operator/flink-service-account-clusterrolebinding.yaml @@ -0,0 +1,14 @@ +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRoleBinding +metadata: + name: {{ .Values.clusterRoleBinding.name }} +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: ClusterRole + name: {{ .Values.clusterRoleBinding.roleName }} +subjects: +{{- range .Values.clusterRoleBinding.subjects }} +- kind: ServiceAccount + name: {{ .name }} + namespace: {{ .namespace }} +{{- end }} \ No newline at end of file diff --git a/src/templates/flink-k8s-operator/service-account.yaml b/src/templates/flink-k8s-operator/service-account.yaml new file mode 100644 index 0000000..899edcd --- /dev/null +++ b/src/templates/flink-k8s-operator/service-account.yaml @@ -0,0 +1,4 @@ +apiVersion: v1 +kind: ServiceAccount +metadata: + name: flink-service-account \ No newline at end of file diff --git a/src/templates/flink-k8s-operator/shared-volume-pvc.yaml b/src/templates/flink-k8s-operator/shared-volume-pvc.yaml new file mode 100644 index 0000000..89606fb --- /dev/null +++ b/src/templates/flink-k8s-operator/shared-volume-pvc.yaml @@ -0,0 +1,11 @@ +apiVersion: v1 +kind: PersistentVolumeClaim +metadata: + name: payload-pvc-nfs +spec: + accessModes: + - ReadWriteMany + resources: + requests: + storage: 1Gi + storageClassName: nfs \ No newline at end of file diff --git a/src/values.yaml b/src/values.yaml index fae630e..60fde1f 100644 --- a/src/values.yaml +++ b/src/values.yaml @@ -219,6 +219,9 @@ flink: jobmanager: statefulset: true +flink-k8s-operator: + enabled: true + grafana: enabled: true grafana.ini: