diff --git a/roles/ocp4_workload_gitops_bootstrap/defaults/main.yml b/roles/ocp4_workload_gitops_bootstrap/defaults/main.yml index 7565c7e..d39d96a 100644 --- a/roles/ocp4_workload_gitops_bootstrap/defaults/main.yml +++ b/roles/ocp4_workload_gitops_bootstrap/defaults/main.yml @@ -49,3 +49,11 @@ ocp4_workload_gitops_bootstrap_application_sync_required: true # false is great # /operation on child Application CRDs. Has no effect on other resource types. # Default: false — existing labs are unaffected unless they opt in. ocp4_workload_gitops_bootstrap_application_ignore_tracking: false + +# Additional syncOptions to include on the ArgoCD Application. +# RespectIgnoreDifferences=true is always included. +# Common additions: +# - SkipDryRunOnMissingResource=true (when operator CRDs are in same app as Subscriptions) +# - CreateNamespace=true +# - ServerSideApply=true +ocp4_workload_gitops_bootstrap_sync_options: [] diff --git a/roles/ocp4_workload_gitops_bootstrap/templates/application.yaml.j2 b/roles/ocp4_workload_gitops_bootstrap/templates/application.yaml.j2 index cfcd3e1..5214618 100644 --- a/roles/ocp4_workload_gitops_bootstrap/templates/application.yaml.j2 +++ b/roles/ocp4_workload_gitops_bootstrap/templates/application.yaml.j2 @@ -33,6 +33,11 @@ spec: selfHeal: false syncOptions: - RespectIgnoreDifferences=true +{% if ocp4_workload_gitops_bootstrap_sync_options | length > 0 %} +{% for opt in ocp4_workload_gitops_bootstrap_sync_options %} + - {{ opt }} +{% endfor %} +{% endif %} ignoreDifferences: - group: "" kind: ConfigMap