From 8e6fcbb3778d921742079b0acc154ed7bb9ae998 Mon Sep 17 00:00:00 2001 From: Alexander Chernov Date: Mon, 5 Feb 2024 13:05:32 +0000 Subject: [PATCH] chore: added support for annotations --- README.md | 3 ++- main.tf | 1 + variables.tf | 5 +++++ 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 4b199d1..7f8bb97 100644 --- a/README.md +++ b/README.md @@ -10,7 +10,7 @@ | Name | Version | |------|---------| -| [kubectl](#provider\_kubectl) | 2.0.0 | +| [kubectl](#provider\_kubectl) | >= 2.0.0 | ## Modules @@ -26,6 +26,7 @@ No modules. | Name | Description | Type | Default | Required | |------|-------------|------|---------|:--------:| +| [annotations](#input\_annotations) | Annotations for argocd Application | `map(string)` | `{}` | no | | [app\_source](#input\_app\_source) | Type of application source (helm, git) | `string` | `"helm"` | no | | [apply\_out\_of\_sync\_only](#input\_apply\_out\_of\_sync\_only) | Currently when syncing using auto sync Argo CD applies every object in the application. Turning on selective sync option which will sync only out-of-sync resources. | `bool` | `false` | no | | [argocd\_namespace](#input\_argocd\_namespace) | The name of the target ArgoCD Namespace | `string` | `"argocd"` | no | diff --git a/main.tf b/main.tf index 8ccd451..7370ffc 100644 --- a/main.tf +++ b/main.tf @@ -7,6 +7,7 @@ locals { namespace = var.argocd_namespace labels = local.labels finalizers = var.cascade_delete == true ? ["resources-finalizer.argocd.argoproj.io"] : [] + annotations = var.annotations } spec = { project = var.project diff --git a/variables.tf b/variables.tf index c7acd5a..17240f0 100644 --- a/variables.tf +++ b/variables.tf @@ -163,3 +163,8 @@ variable "skip_crd" { default = false description = "If set to true, it will skip the deployment of crd entities from the helm chart" } +variable "annotations" { + type = map(string) + description = "Annotations for argocd Application" + default = {} +} \ No newline at end of file