skopeo fails to copy with signature COSIGN_DOCKER_MEDIA_TYPES=1
#2599
Labels
kind/feature
A request for, or a PR adding, new functionality
Description
When attempting to copy a Docker image along with its signature between registries using
skopeo
, the operation fails if the signature was created withcosign
while theCOSIGN_DOCKER_MEDIA_TYPES=1
environment variable was set.Steps to Reproduce
Error Message
Expected Behavior
Skopeo should successfully copy both the image and its signature to the target registry.
Actual Behavior
Skopeo fails with an error about unexpected MIME type for the signature manifest.
Environment
Additional Information
The
COSIGN_DOCKER_MEDIA_TYPES=1
environment variable causes Cosign to useapplication/vnd.docker.distribution.manifest.v2+json
as the mediaType for the signature manifest, which Skopeo apparently doesn't expect or can't handle.Proposed Fix
In
docker_client.go
, around line 1024, modify the condition to accept both manifest types:If you agree with this, I can collaborate with the pr a image
The text was updated successfully, but these errors were encountered: