Skip to content

Commit

Permalink
feat: configure ArgoCD Application finalizers and source.plugin (#56)
Browse files Browse the repository at this point in the history
  • Loading branch information
Zebradil authored Aug 21, 2023
1 parent 87aafa3 commit 80940aa
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
7 changes: 7 additions & 0 deletions internal/myks/assets/data-schema.ytt.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,10 @@ argocd:
name: ""
#! Prefix of the ArgoCD application name.
prefix: ""
#! List of finalizers of the ArgoCD application.
#! See https://github.com/argoproj/argo-cd/blob/dc8d729078df6fe9d4c480df0e67b2402af75e0b/docs/user-guide/app_deletion.md
#@schema/default ["resources-finalizer.argocd.argoproj.io"]
finalizers: [""]
destination:
#! spec.destination.name of the ArgoCD application.
#! If not set, defaults to the name of the current environment.
Expand All @@ -32,6 +36,9 @@ argocd:
#! If not set, defaults to the destination path of the currently rendered application.
#! With the default myks configuration: `rendered/envs/<environment.id>/<app.name>`
path: ""
#! spec.source.plugin of the ArgoCD application.
#@schema/type any=True
plugin: {}
#! spec.source.repoURL of the ArgoCD application.
#! If not set, defaults to the current git repository URL.
repoURL: ""
Expand Down
2 changes: 2 additions & 0 deletions internal/myks/templates/argocd/application.ytt.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ kind: Application
metadata:
name: #@ app_name
namespace: #@ a.namespace
finalizers: #@ a.app.finalizers or []
spec:
project: #@ project_name
destination:
Expand All @@ -24,6 +25,7 @@ spec:
namespace: #@ a.app.destination.namespace or a.app.name
source:
path: #@ a.app.source.path
plugin: #@ a.app.source.plugin
repoURL: #@ a.app.source.repoURL
targetRevision: #@ a.app.source.targetRevision
syncPolicy:
Expand Down

0 comments on commit 80940aa

Please sign in to comment.