From a13da7ed74186aa69e2e206e41b0ceaea7a9e9dc Mon Sep 17 00:00:00 2001 From: Sebastian Poxhofer <secustor@users.noreply.github.com> Date: Tue, 26 Oct 2021 12:49:24 +0200 Subject: [PATCH] fix(manager/helmsman): add helm datasource to deps (#12330) --- .../helmsman/__snapshots__/extract.spec.ts.snap | 10 ++++++++++ lib/manager/helmsman/extract.ts | 2 ++ 2 files changed, 12 insertions(+) diff --git a/lib/manager/helmsman/__snapshots__/extract.spec.ts.snap b/lib/manager/helmsman/__snapshots__/extract.spec.ts.snap index 240088271e..1c4252ff55 100644 --- a/lib/manager/helmsman/__snapshots__/extract.spec.ts.snap +++ b/lib/manager/helmsman/__snapshots__/extract.spec.ts.snap @@ -5,6 +5,7 @@ Object { "deps": Array [ Object { "currentValue": "19.0.3", + "datasource": "helm", "depName": "kube-prometheus", "lookupName": "kube-prometheus-stack", "registryUrls": Array [ @@ -13,6 +14,7 @@ Object { }, Object { "currentValue": "2.6.0", + "datasource": "helm", "depName": "loki", "lookupName": "loki", "registryUrls": Array [ @@ -21,6 +23,7 @@ Object { }, Object { "currentValue": "0.7.7", + "datasource": "helm", "depName": "tempo", "lookupName": "tempo", "registryUrls": Array [ @@ -29,6 +32,7 @@ Object { }, Object { "currentValue": "0.6.0", + "datasource": "helm", "depName": "otlp-collector", "lookupName": "opentelemetry-collector", "registryUrls": Array [ @@ -37,6 +41,7 @@ Object { }, Object { "currentValue": "0.25.0", + "datasource": "helm", "depName": "strimzi-operator", "lookupName": "strimzi-kafka-operator", "registryUrls": Array [ @@ -44,27 +49,32 @@ Object { ], }, Object { + "datasource": "helm", "depName": "strimzi-operator-missing-version", "skipReason": "no-version", }, Object { "currentValue": "2.6.0", + "datasource": "helm", "depName": "loki-no-registry-ref", "lookupName": "loki", "skipReason": "no-repository", }, Object { "currentValue": "0.7.7", + "datasource": "helm", "depName": "tempo-no-registry-ref", "skipReason": "invalid-url", }, Object { "currentValue": "19.0.3", + "datasource": "helm", "depName": "kube-prometheus-no-lookup-name", "skipReason": "invalid-name", }, Object { "currentValue": "0.6.0", + "datasource": "helm", "depName": "otlp-collector-no-chart", "skipReason": "invalid-url", }, diff --git a/lib/manager/helmsman/extract.ts b/lib/manager/helmsman/extract.ts index e81dc2a638..6fbbd43bae 100644 --- a/lib/manager/helmsman/extract.ts +++ b/lib/manager/helmsman/extract.ts @@ -1,5 +1,6 @@ import is from '@sindresorhus/is'; import { load } from 'js-yaml'; +import { HelmDatasource } from '../../datasource/helm'; import { logger } from '../../logger'; import { SkipReason } from '../../types'; import { regEx } from '../../util/regex'; @@ -11,6 +12,7 @@ const chartRegex = regEx('^(?<registryRef>[^/]*)/(?<lookupName>[^/]*)$'); function createDep(key: string, doc: HelmsmanDocument): PackageDependency { const dep: PackageDependency = { depName: key, + datasource: HelmDatasource.id, }; const anApp = doc.apps[key]; if (!anApp) { -- GitLab