diff options
author | cdoern <cdoern@redhat.com> | 2022-05-23 14:12:48 -0400 |
---|---|---|
committer | Charlie Doern <cdoern@redhat.com> | 2022-06-28 08:54:19 -0400 |
commit | 6d3520e8b7d7f57d389da08d1c8104c2cfbdd016 (patch) | |
tree | a0c045201f5db57fd43e66380409376f602d24f4 /test/e2e/image_scp_test.go | |
parent | c66a489b75b7bc68c341f0ff39d7beef95569878 (diff) | |
download | podman-6d3520e8b7d7f57d389da08d1c8104c2cfbdd016.tar.gz podman-6d3520e8b7d7f57d389da08d1c8104c2cfbdd016.tar.bz2 podman-6d3520e8b7d7f57d389da08d1c8104c2cfbdd016.zip |
podman image scp remote support & podman image scp tagging
add support for podman-remote image scp as well as direct access via the API. This entailed
a full rework of the layering of image scp functions as well as the usual API plugging and type creation
also, implemented podman image scp tagging. which makes the syntax much more readable and allows users t tag the new image
they are loading to the local/remote machine:
allow users to pass a "new name" for the image they are transferring
`podman tag` as implemented creates a new image im `image list` when tagging, so this does the same
meaning that when transferring images with tags, podman on the remote machine/user will load two images
ex: `podman image scp computer1::alpine computer2::foobar` creates alpine:latest and localhost/foobar on the remote host
implementing tags means removal of the flexible syntax. In the currently released podman image scp, the user can either specify
`podman image scp source::img dest::` or `podman image scp dest:: source::img`. However, with tags this task becomes really hard to check
which is the image (src) and which is the new tag (dst). Removal of that streamlines the arg parsing process
Signed-off-by: Charlie Doern <cdoern@redhat.com>
Diffstat (limited to 'test/e2e/image_scp_test.go')
-rw-r--r-- | test/e2e/image_scp_test.go | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/test/e2e/image_scp_test.go b/test/e2e/image_scp_test.go index 53681f05b..77fe810bd 100644 --- a/test/e2e/image_scp_test.go +++ b/test/e2e/image_scp_test.go @@ -50,18 +50,12 @@ var _ = Describe("podman image scp", func() { }) It("podman image scp bogus image", func() { - if IsRemote() { - Skip("this test is only for non-remote") - } scp := podmanTest.Podman([]string{"image", "scp", "FOOBAR"}) scp.WaitWithDefaultTimeout() Expect(scp).Should(ExitWithError()) }) It("podman image scp with proper connection", func() { - if IsRemote() { - Skip("this test is only for non-remote") - } cmd := []string{"system", "connection", "add", "--default", "QA", @@ -86,7 +80,10 @@ var _ = Describe("podman image scp", func() { // This tests that the input we are given is validated and prepared correctly // The error given should either be a missing image (due to testing suite complications) or a no such host timeout on ssh Expect(scp).Should(ExitWithError()) - Expect(scp.ErrorToString()).Should(ContainSubstring("no such host")) + // podman-remote exits with a different error + if !IsRemote() { + Expect(scp.ErrorToString()).Should(ContainSubstring("no such host")) + } }) |