summaryrefslogtreecommitdiff
path: root/pkg/domain/infra/tunnel/manifest.go
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2020-05-07 19:10:32 +0200
committerGitHub <noreply@github.com>2020-05-07 19:10:32 +0200
commit1d3cdf9a4642df073becb54d178d6b1959526a47 (patch)
tree8648b5f2e821b25b7c2211d1389554666579e42c /pkg/domain/infra/tunnel/manifest.go
parent0799e52d15c6d63434ea685095d4c20c20d034f3 (diff)
parent5621f5199d0aeaefae77db920866d7aeea9d1e7b (diff)
downloadpodman-1d3cdf9a4642df073becb54d178d6b1959526a47.tar.gz
podman-1d3cdf9a4642df073becb54d178d6b1959526a47.tar.bz2
podman-1d3cdf9a4642df073becb54d178d6b1959526a47.zip
Merge pull request #5961 from QiWang19/manifest-remove-push
Manifest remove, push
Diffstat (limited to 'pkg/domain/infra/tunnel/manifest.go')
-rw-r--r--pkg/domain/infra/tunnel/manifest.go15
1 files changed, 15 insertions, 0 deletions
diff --git a/pkg/domain/infra/tunnel/manifest.go b/pkg/domain/infra/tunnel/manifest.go
index 3d3196019..7d9a0fce1 100644
--- a/pkg/domain/infra/tunnel/manifest.go
+++ b/pkg/domain/infra/tunnel/manifest.go
@@ -91,3 +91,18 @@ func (ir *ImageEngine) ManifestAnnotate(ctx context.Context, names []string, opt
}
return fmt.Sprintf("%s :%s", updatedListID, names[1]), nil
}
+
+// ManifestRemove removes the digest from manifest list
+func (ir *ImageEngine) ManifestRemove(ctx context.Context, names []string) (string, error) {
+ updatedListID, err := manifests.Remove(ctx, names[0], names[1])
+ if err != nil {
+ return updatedListID, errors.Wrapf(err, "error removing from manifest %s", names[0])
+ }
+ return fmt.Sprintf("%s :%s\n", updatedListID, names[1]), nil
+}
+
+// ManifestPush pushes a manifest list or image index to the destination
+func (ir *ImageEngine) ManifestPush(ctx context.Context, names []string, opts entities.ManifestPushOptions) error {
+ _, err := manifests.Push(ctx, names[0], &names[1], &opts.All)
+ return err
+}