1
0
mirror of https://pagure.io/fedora-qa/os-autoinst-distri-fedora.git synced 2024-11-21 21:43:08 +00:00

toolbox: handle OCI images (as produced by Kiwi)

We changed to building toolbox container images with Kiwi. These
are OCI archives, not docker archives. So we need to call skopeo
appropriately.

Signed-off-by: Adam Williamson <awilliam@redhat.com>
This commit is contained in:
Adam Williamson 2024-03-14 14:34:38 -07:00
parent 4ee74a0bca
commit dc7ff01f27

View File

@ -27,8 +27,8 @@ sub run {
assert_script_run "curl -o /var/tmp/toolbox.tar.gz $image", 300; assert_script_run "curl -o /var/tmp/toolbox.tar.gz $image", 300;
# this registers the downloaded image such that `toolbox create` # this registers the downloaded image such that `toolbox create`
# will use it, rather than downloading one. it takes a while # will use it, rather than downloading one. it takes a while
my $format = $image =~ "oci" ? "oci-archive" : "docker-archive";
assert_script_run "skopeo copy docker-archive:/var/tmp/toolbox.tar.gz containers-storage:registry.fedoraproject.org/fedora-toolbox:$relnum", 600; assert_script_run "skopeo copy $format:/var/tmp/toolbox.tar.gz containers-storage:registry.fedoraproject.org/fedora-toolbox:$relnum", 600;
# we do not pass -y this time as we do not want to allow a # we do not pass -y this time as we do not want to allow a
# download, if toolbox wants to do one, something has gone # download, if toolbox wants to do one, something has gone
# wrong. unfortunately there is no -n so we just have to let # wrong. unfortunately there is no -n so we just have to let