diff --git a/applications/atlantis-resources.yaml b/applications/atlantis-resources.yaml index 70f77d1c..5fb7b07e 100644 --- a/applications/atlantis-resources.yaml +++ b/applications/atlantis-resources.yaml @@ -4,24 +4,35 @@ metadata: name: atlantis-resources namespace: argocd spec: + goTemplate: true generators: - list: elements: - cluster: https://kubernetes.default.svc env: prod + autoSync: false + prune: false # - cluster: https://staging-vcluster.staging-vcluster # env: staging template: metadata: - name: '{{ env }}-atlantis-resources' + name: "{{ .env }}-atlantis-resources" spec: project: aux syncPolicy: automated: {} destination: - server: '{{ cluster }}' + server: "{{ .cluster }}" namespace: atlantis sources: {} # - repoURL: https://gitlab.com/oceanbox/manifests.git # targetRevision: main # path: 'resources/atlantis/manifests/{{ env }}' + templatePatch: | + {{- if .autoSync }} + spec: + syncPolicy: + automated: + prune: {{ .prune }} + selfHeal: false + {{- end }}