From b65a490515171df309bb2934720e06dfe5c47bfc Mon Sep 17 00:00:00 2001 From: sanscfs Date: Fri, 28 Aug 2026 12:55:42 +0300 Subject: [PATCH] fix(argocd): add CICD DomainTypes to application collect/extract subtasks collectApplications and extractApplications had no DomainTypes, while the convertApplications / *SyncOperations subtasks carry DomainTypes [CICD]. Blueprint plan generation (MakePipelinePlanSubtasks) only includes a subtask whose DomainTypes intersect the scope config's entities (typically ["CICD"]). With no DomainTypes, the application subtasks were never generated into the blueprint plan, so _tool_argocd_applications.dest_namespace was never populated and detectEnvironment() classified every ArgoCD deployment as TESTING instead of PRODUCTION. Add DomainTypes: [CICD] so the application collect/extract subtasks are generated alongside the sync-operation ones, letting dest_namespace populate natively. Co-Authored-By: Claude Fable 5 --- backend/plugins/argocd/tasks/application_collector.go | 1 + backend/plugins/argocd/tasks/application_extractor.go | 1 + 2 files changed, 2 insertions(+) diff --git a/backend/plugins/argocd/tasks/application_collector.go b/backend/plugins/argocd/tasks/application_collector.go index 67ffabfe1e0..a31e6350535 100644 --- a/backend/plugins/argocd/tasks/application_collector.go +++ b/backend/plugins/argocd/tasks/application_collector.go @@ -37,6 +37,7 @@ var CollectApplicationsMeta = plugin.SubTaskMeta{ EntryPoint: CollectApplications, EnabledByDefault: true, Description: "Collect applications from ArgoCD API", + DomainTypes: []string{plugin.DOMAIN_TYPE_CICD}, } func CollectApplications(taskCtx plugin.SubTaskContext) errors.Error { diff --git a/backend/plugins/argocd/tasks/application_extractor.go b/backend/plugins/argocd/tasks/application_extractor.go index 1c789999c79..dfbf0e8a6c5 100644 --- a/backend/plugins/argocd/tasks/application_extractor.go +++ b/backend/plugins/argocd/tasks/application_extractor.go @@ -34,6 +34,7 @@ var ExtractApplicationsMeta = plugin.SubTaskMeta{ EntryPoint: ExtractApplications, EnabledByDefault: true, Description: "Extract applications from raw data", + DomainTypes: []string{plugin.DOMAIN_TYPE_CICD}, DependencyTables: []string{RAW_APPLICATION_TABLE}, ProductTables: []string{models.ArgocdApplication{}.TableName()}, }