mirror of
https://github.com/project-zot/zot.git
synced 2026-06-15 20:07:55 +08:00
fix(sync): also add docker v2 mediatype as supported in sync (#1084)
Signed-off-by: Petu Eusebiu <peusebiu@cisco.com>
This commit is contained in:
@@ -53,13 +53,12 @@ function teardown_file() {
|
||||
}
|
||||
|
||||
# sync image
|
||||
@test "sync docker image on demand" {
|
||||
run skopeo --insecure-policy copy --src-tls-verify=false \
|
||||
@test "sync docker image list on demand" {
|
||||
run skopeo --insecure-policy copy --multi-arch=all --src-tls-verify=false \
|
||||
docker://127.0.0.1:8090/registry \
|
||||
oci:${TEST_DATA_DIR}
|
||||
[ "$status" -eq 0 ]
|
||||
|
||||
|
||||
run curl http://127.0.0.1:8090/v2/_catalog
|
||||
[ "$status" -eq 0 ]
|
||||
[ $(echo "${lines[-1]}" | jq '.repositories[]') = '"registry"' ]
|
||||
@@ -67,3 +66,17 @@ function teardown_file() {
|
||||
[ "$status" -eq 0 ]
|
||||
[ $(echo "${lines[-1]}" | jq '.tags[]') = '"latest"' ]
|
||||
}
|
||||
|
||||
@test "sync docker image on demand" {
|
||||
run skopeo --insecure-policy copy --src-tls-verify=false \
|
||||
docker://127.0.0.1:8090/archlinux \
|
||||
oci:${TEST_DATA_DIR}
|
||||
[ "$status" -eq 0 ]
|
||||
|
||||
run curl http://127.0.0.1:8090/v2/_catalog
|
||||
[ "$status" -eq 0 ]
|
||||
[ $(echo "${lines[-1]}" | jq '.repositories[0]') = '"archlinux"' ]
|
||||
run curl http://127.0.0.1:8090/v2/registry/tags/list
|
||||
[ "$status" -eq 0 ]
|
||||
[ $(echo "${lines[-1]}" | jq '.tags[]') = '"latest"' ]
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user