Skip to content

Commit

Permalink
Add comment
Browse files Browse the repository at this point in the history
Signed-off-by: Natalie Arellano <narellano@vmware.com>
  • Loading branch information
natalieparellano committed Jun 30, 2023
1 parent eb08a3c commit ff750f3
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion platform/run_image.go
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,18 @@ func byRegistry(reg string, images []string, checkReadAccess CheckReadAccess, ke
return ""
}

// GetRunImageForExport TODO
// GetRunImageForExport takes platform inputs and returns run image information
// for populating the io.buildpacks.lifecycle.metadata on the exported app image.
// The run image information is read from:
// - stack.toml for older platforms
// - run.toml for newer platforms, where the run image information returned is
// - the first set of image & mirrors that contains the platform-provided run image, or
// - the platform-provided run image if extensions were used and the image was not found, or
// - the first set of image & mirrors in run.toml
//
// The "platform-provided run image" is the run image "image" in analyzed.toml,
// NOT the run image "reference",
// as the run image "reference" could be a daemon image ID (which we'd not expect to find in run.toml).
func GetRunImageForExport(inputs LifecycleInputs) (files.RunImageForExport, error) {
if inputs.PlatformAPI.LessThan("0.12") {
stackMD, err := files.ReadStack(inputs.StackPath, cmd.DefaultLogger)
Expand Down

0 comments on commit ff750f3

Please sign in to comment.