Skip to content

Commit

Permalink
fix(core): Remove status.Image update post publish
Browse files Browse the repository at this point in the history
  • Loading branch information
gansheer committed Jun 6, 2024
1 parent 2ba1222 commit af9daba
Showing 1 changed file with 0 additions and 20 deletions.
20 changes: 0 additions & 20 deletions pkg/controller/build/monitor_pod.go
Original file line number Diff line number Diff line change
Expand Up @@ -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)
Expand Down Expand Up @@ -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 {
Expand Down

0 comments on commit af9daba

Please sign in to comment.