From 82d89cf36c5756db4d6722a590e69899e098626b Mon Sep 17 00:00:00 2001 From: Gaelle Fournier Date: Thu, 6 Jun 2024 14:34:58 +0200 Subject: [PATCH] fix(core): Remove status.Image update post publish --- pkg/controller/build/monitor_pod.go | 20 -------------------- 1 file changed, 20 deletions(-) diff --git a/pkg/controller/build/monitor_pod.go b/pkg/controller/build/monitor_pod.go index b45948c549..ac7a63973f 100644 --- a/pkg/controller/build/monitor_pod.go +++ b/pkg/controller/build/monitor_pod.go @@ -143,7 +143,6 @@ func (action *monitorPodAction) Handle(ctx context.Context, build *v1.Build) (*v // Account for the Build metrics observeBuildResult(build, build.Status.Phase, buildCreator, duration) - build.Status.Image = publishTaskImageName(build.Spec.Tasks) // operator supported publishing tasks should provide the digest in the builder command process execution if !operatorSupportedPublishingStrategy(build.Spec.Tasks) { build.Status.Digest = publishTaskDigest(build.Spec.Tasks, pod.Status.ContainerStatuses) @@ -349,25 +348,6 @@ func publishTask(tasks []v1.Task) *v1.Task { return nil } -func publishTaskImageName(tasks []v1.Task) string { - t := publishTask(tasks) - if t == nil { - return "" - } - switch { - case t.Custom != nil: - return t.Custom.PublishingImage - case t.Spectrum != nil: - return t.Spectrum.Image - case t.Jib != nil: - return t.Jib.Image - case t.S2i != nil: - return t.S2i.Image - } - - return "" -} - func publishTaskName(tasks []v1.Task) string { t := publishTask(tasks) if t == nil {