lifecycle: Run image in `pack inspect` is not correctly updated after rebasing

Summary

Run image in pack inspect <img-name-1> is not correctly updated after running pack rebase <img-name-1> --run-image <img-name-2>.


Reproduction

Steps
  1. Build an image with a buildpack and call it <img-name-1>
  2. Build a run image with docker build <run-img> (Optional Step)
  3. Run pack inspect <img-name-1> --output json and note the content in the run image part
  4. Run pack rebase <img-name-1> --run-image <run-img> to rebase image 1 with a new run image
  5. Run pack inspect <img-name-1> --output json and note the content in the run image part again.
Current behavior

The run image field when running pack inspect is not reflected correctly after rebase command.

Expected behavior

The run image name and tag should be changed after rebasing with a new run image.

About this issue

  • Original URL
  • State: closed
  • Created a year ago
  • Comments: 30 (16 by maintainers)

Most upvoted comments

Hey guys 👋 I’ll be checking this issue during the weekend

Ah okay - then there is still ambiguity here (maybe we’re truncating the tag, maybe we’re failing to update the run image metadata). Would you mind conducting a test on the artifact from https://github.com/buildpacks/lifecycle/actions/runs/5348592701/jobs/9698656837 (when it finishes). You will need to provide CNB_PLATFORM_API=0.12 to the rebaser.

@harryli0108 @daniv-msft could we trouble you for a review on https://github.com/buildpacks/spec/pull/360? Is this in line with what you were expecting?

I’m going to move this issue over to the lifecycle as it would be implemented there. It should be a small change. If we act soon we could fold this into the next minor release. Would anyone be willing to take this on?

Created this PR https://github.com/buildpacks/spec/pull/360 we can discuss it there and then continue with the implementation here as @natalieparellano suggested 😉