Skip to content

Commit

Permalink
Fix replace with non compliant image mediatypes
Browse files Browse the repository at this point in the history
Signed-off-by: Stef Graces <stefgraces@hotmail.com>
  • Loading branch information
Stef Graces authored and stgrace committed Feb 21, 2025
1 parent eac84af commit 1334aea
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pkg/oci/mutate/signatures.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@ package mutate

import (
v1 "github.com/google/go-containerregistry/pkg/v1"
"github.com/google/go-containerregistry/pkg/v1/empty"
"github.com/google/go-containerregistry/pkg/v1/mutate"
"github.com/sigstore/cosign/v2/internal/pkg/now"
"github.com/sigstore/cosign/v2/pkg/oci"
"github.com/sigstore/cosign/v2/pkg/oci/empty"
)

const maxLayers = 1000
Expand Down Expand Up @@ -83,7 +83,7 @@ func ReplaceSignatures(base oci.Signatures) (oci.Signatures, error) {
Annotations: ann,
})
}
img, err := mutate.Append(empty.Image, adds...)
img, err := mutate.Append(empty.Signatures(), adds...)
if err != nil {
return nil, err
}
Expand Down

0 comments on commit 1334aea

Please # to comment.