diff --git a/roles/ocp4_workload_openshift_gitops/defaults/main.yml b/roles/ocp4_workload_openshift_gitops/defaults/main.yml index ef281d54..d8cba240 100644 --- a/roles/ocp4_workload_openshift_gitops/defaults/main.yml +++ b/roles/ocp4_workload_openshift_gitops/defaults/main.yml @@ -51,6 +51,17 @@ ocp4_workload_openshift_gitops_controller_limits_memory: 2Gi # Reduce this value if you want to sync more frequently ocp4_workload_openshift_gitops_controller_app_sync: 3m +# Optional command parameters for the ArgoCD custom resource (spec.cmdParams). +# Requires an OpenShift GitOps version that supports spec.cmdParams. +# Values must be strings. Empty leaves the operator's defaults unchanged. +ocp4_workload_openshift_gitops_cmd_params: {} +# Example: keep per-resource health in Redis instead of the Application CR. +# Upstream Argo CD 3.x defaults to false; OpenShift GitOps retains true for compatibility. +# Do not use this example if RHACM is in use, or other integrations require +# per-resource health in Application CR status. +# ocp4_workload_openshift_gitops_cmd_params: +# controller.resource.health.persist: "false" + # Redis ocp4_workload_openshift_gitops_redis_update: false ocp4_workload_openshift_gitops_redis_requests_cpu: 250m diff --git a/roles/ocp4_workload_openshift_gitops/templates/openshift-gitops.yaml.j2 b/roles/ocp4_workload_openshift_gitops/templates/openshift-gitops.yaml.j2 index 566a8035..8e34b239 100644 --- a/roles/ocp4_workload_openshift_gitops/templates/openshift-gitops.yaml.j2 +++ b/roles/ocp4_workload_openshift_gitops/templates/openshift-gitops.yaml.j2 @@ -6,6 +6,10 @@ metadata: namespace: openshift-gitops spec: kustomizeBuildOptions: "--enable-helm --enable-alpha-plugins" +{% if ocp4_workload_openshift_gitops_cmd_params | length > 0 %} + cmdParams: + {{ ocp4_workload_openshift_gitops_cmd_params | to_nice_yaml | indent(4) }} +{% endif %} {% if ocp4_workload_openshift_gitops_resource_tracking_method | length > 0 %} resourceTrackingMethod: {{ ocp4_workload_openshift_gitops_resource_tracking_method }} {% endif %}