From 61918c2cba8e6466c6c22d3a709c1a4968d9e1c2 Mon Sep 17 00:00:00 2001 From: Dmitry Dodzin Date: Mon, 11 Nov 2024 11:54:35 +0200 Subject: [PATCH] Add permissions and options for applicationPauseAutoSync --- mirrord-operator/Chart.yaml | 2 +- mirrord-operator/templates/cluster-role.yaml | 10 ++++++++++ mirrord-operator/templates/deployment.yaml | 4 ++++ mirrord-operator/values.yaml | 3 +++ 4 files changed, 18 insertions(+), 1 deletion(-) diff --git a/mirrord-operator/Chart.yaml b/mirrord-operator/Chart.yaml index 4b9b142..0fdf368 100644 --- a/mirrord-operator/Chart.yaml +++ b/mirrord-operator/Chart.yaml @@ -15,7 +15,7 @@ type: application # This is the chart version. This version number should be incremented each time you make changes # to the chart and its templates, including the app version. # Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 1.10.4 +version: 1.10.5 # This is the version number of the application being deployed. This version number should be # incremented each time you make changes to the application. Versions are not expected to diff --git a/mirrord-operator/templates/cluster-role.yaml b/mirrord-operator/templates/cluster-role.yaml index 7ddc264..134090b 100644 --- a/mirrord-operator/templates/cluster-role.yaml +++ b/mirrord-operator/templates/cluster-role.yaml @@ -139,6 +139,16 @@ rules: - list - watch {{- end }} +{{- if .Values.operator.applicationPauseAutoSync }} +- apiGroups: + - argoproj.io + resources: + - applications + verbs: + - list + - get + - patch +{{- end }} --- apiVersion: rbac.authorization.k8s.io/v1 kind: ClusterRole diff --git a/mirrord-operator/templates/deployment.yaml b/mirrord-operator/templates/deployment.yaml index d615320..2e79a25 100644 --- a/mirrord-operator/templates/deployment.yaml +++ b/mirrord-operator/templates/deployment.yaml @@ -72,6 +72,10 @@ spec: value: {{ .Values.operator.sqsSplitting | ternary "true" "false" | quote }} - name: OPERATOR_KAFKA_SPLITTING value: {{ .Values.operator.kafkaSplitting | ternary "true" "false" | quote }} + {{- if .Values.operator.applicationPauseAutoSync }} + - name: OPERATOR_APPLICATION_PAUSE_AUTO_SYNC + value: "true" + {{- end }} - name: OPERATOR_JSON_LOG value: {{ .Values.operator.jsonLog | ternary "true" "false" | quote }} - name: OPERATOR_AGENT_CONFIG diff --git a/mirrord-operator/values.yaml b/mirrord-operator/values.yaml index 00c0152..550db17 100644 --- a/mirrord-operator/values.yaml +++ b/mirrord-operator/values.yaml @@ -22,6 +22,9 @@ operator: sqsSplitting: false # Has to be set to `true` in order to use the Kafka queue splitting feature. kafkaSplitting: false + # Has to be set to `true` in order to use the argocd application auto-sync pause feature. + applicationPauseAutoSync: false + # imagePullSecrets: # - name: value