diff --git a/pkg/skaffold/deploy/helm/helm.go b/pkg/skaffold/deploy/helm/helm.go index b1b853beac8..99dca27ec4c 100644 --- a/pkg/skaffold/deploy/helm/helm.go +++ b/pkg/skaffold/deploy/helm/helm.go @@ -295,7 +295,7 @@ func (h *Deployer) Deploy(ctx context.Context, out io.Writer, builds []graph.Art // Otherwise, templates have no way to use the images that were built. // Skip warning for multi-config projects as there can be artifacts without any usage in the current deployer. if !h.isMultiConfig { - warnAboutUnusedImages(builds, manifests) + h.warnAboutUnusedImages(builds, manifests) } // Collect namespaces in a string @@ -303,7 +303,7 @@ func (h *Deployer) Deploy(ctx context.Context, out io.Writer, builds []graph.Art for ns := range nsMap { namespaces = append(namespaces, ns) } - deployedImages, _ := manifests.GetImages(manifest.NewResourceSelectorImages(manifest.TransformAllowlist, manifest.TransformDenylist)) + deployedImages, _ := manifests.GetImages(manifest.NewResourceSelectorImages(h.transformableAllowlist, h.transformableDenylist)) h.TrackBuildArtifacts(builds, deployedImages) h.trackNamespaces(namespaces) @@ -622,9 +622,9 @@ func (h *Deployer) packageChart(ctx context.Context, r latest.HelmRelease) (stri return output[idx:], nil } -func warnAboutUnusedImages(builds []graph.Artifact, manifests manifest.ManifestList) { +func (h *Deployer) warnAboutUnusedImages(builds []graph.Artifact, manifests manifest.ManifestList) { seen := map[string]bool{} - images, _ := manifests.GetImages(manifest.NewResourceSelectorImages(manifest.TransformAllowlist, manifest.TransformDenylist)) + images, _ := manifests.GetImages(manifest.NewResourceSelectorImages(h.transformableAllowlist, h.transformableDenylist)) for _, a := range images { seen[a.Tag] = true } diff --git a/pkg/skaffold/deploy/kubectl/kubectl.go b/pkg/skaffold/deploy/kubectl/kubectl.go index d4187d627c5..1b5e8fdef37 100644 --- a/pkg/skaffold/deploy/kubectl/kubectl.go +++ b/pkg/skaffold/deploy/kubectl/kubectl.go @@ -268,7 +268,7 @@ func (k *Deployer) Deploy(ctx context.Context, out io.Writer, builds []graph.Art endTrace(instrumentation.TraceEndError(err)) return err } - deployedImages, _ := manifests.GetImages(manifest.NewResourceSelectorImages(manifest.TransformAllowlist, manifest.TransformDenylist)) + deployedImages, _ := manifests.GetImages(manifest.NewResourceSelectorImages(k.transformableAllowlist, k.transformableDenylist)) k.TrackBuildArtifacts(builds, deployedImages) k.statusMonitor.RegisterDeployManifests(manifests)