Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ( // ErrArtifactNotFound indicates that the requested artifact was not found // in the registry. ErrArtifactNotFound = errors.New("artifact not found") // ErrLayerNotFound indicates that the requested layer was not found in the // OCI artifact provided. ErrLayerNotFound = errors.New("layer not found") )
Functions ¶
This section is empty.
Types ¶
type PullerMock ¶
PullerMock is a mock hub.OCIPuller implementation.
func (*PullerMock) PullLayer ¶
func (m *PullerMock) PullLayer( ctx context.Context, ref, mediaType, username, password string, ) (ocispec.Descriptor, []byte, error)
PullLayer implements the hub.OCIPuller interface.
type SignatureChecker ¶ added in v1.5.0
type SignatureChecker struct{}
SignatureChecker is a hub.OCISignatureChecker implementation.
func (*SignatureChecker) HasCosignSignature ¶ added in v1.5.0
func (c *SignatureChecker) HasCosignSignature( ctx context.Context, ref, username, password string, ) (bool, error)
HasCosignSignature checks if the OCI artifact identified by the reference provided has a cosign (sigstore) signature.
type SignatureCheckerMock ¶ added in v1.5.0
SignatureCheckerMock is a mock implementation of the hub.OCISignatureChecker interface.
func (*SignatureCheckerMock) HasCosignSignature ¶ added in v1.5.0
func (m *SignatureCheckerMock) HasCosignSignature( ctx context.Context, ref, username, password string, ) (bool, error)
HasCosignSignature implements the OCITagsGetter interface.
type TagsGetter ¶ added in v1.5.0
type TagsGetter struct{}
OCITagsGetter provides a mechanism to get all the version tags available for a given repository in a OCI registry. Tags that aren't valid semver versions will be filtered out.
func (*TagsGetter) Tags ¶ added in v1.5.0
func (tg *TagsGetter) Tags(ctx context.Context, r *hub.Repository, onlySemver bool) ([]string, error)
Tags returns a list with the tags available for the provided repository.
type TagsGetterMock ¶ added in v1.5.0
TagsGetterMock is a mock implementation of the hub.OCITagsGetter interface.
func (*TagsGetterMock) Tags ¶ added in v1.5.0
func (m *TagsGetterMock) Tags(ctx context.Context, r *hub.Repository, onlySemver bool) ([]string, error)
Tags implements the OCITagsGetter interface.