Skip to content

Commit

Permalink
libimage/ManifestPushOptions: add AddCompression from #1585
Browse files Browse the repository at this point in the history
Podman uses different API for pushing manifest list,
add `AddCompression` to ManifestPushOptions, which is implemented
here: #1585

[NO NEW TESTS NEEDED]
Tests are added here: #1585

Signed-off-by: Aditya R <[email protected]>
  • Loading branch information
flouthoc committed Aug 1, 2023
1 parent 5e913f5 commit 959d817
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions libimage/manifest_list.go
Original file line number Diff line number Diff line change
Expand Up @@ -415,6 +415,8 @@ type ManifestListPushOptions struct {
ImageListSelection imageCopy.ImageListSelection
// Use when selecting only specific imags.
Instances []digest.Digest
// add existing instances with requested compression algorithms to manifest list
AddCompression []string
}

// Push pushes a manifest to the specified destination.
Expand Down Expand Up @@ -446,6 +448,7 @@ func (m *ManifestList) Push(ctx context.Context, destination string, options *Ma
defer copier.close()

pushOptions := manifests.PushOptions{
AddCompression: options.AddCompression,
Store: m.image.runtime.store,
SystemContext: copier.systemContext,
ImageListSelection: options.ImageListSelection,
Expand Down

0 comments on commit 959d817

Please sign in to comment.