Documentation ¶
Index ¶
- Constants
- Variables
- func GetContainerBlob(ctx context.Context, opts *BlobSearchOptions) (*packages.PackageFileDescriptor, error)
- func GetContainerBlobs(ctx context.Context, opts *BlobSearchOptions) ([]*packages.PackageFileDescriptor, error)
- func GetImageTags(ctx context.Context, ownerID int64, image string, n int, last string) ([]string, error)
- func GetManifestVersions(ctx context.Context, opts *BlobSearchOptions) ([]*packages.PackageVersion, error)
- func GetRepositories(ctx context.Context, actor *user_model.User, n int, last string) ([]string, error)
- func SearchExpiredUploadedBlobs(ctx context.Context, olderThan time.Duration) ([]*packages.PackageFile, error)
- func SearchImageTags(ctx context.Context, opts *ImageTagsSearchOptions) ([]*packages.PackageVersion, int64, error)
- type BlobSearchOptions
- type ImageTagsSearchOptions
Constants ¶
View Source
const ( ManifestFilename = "manifest.json" UploadVersion = "_upload" )
Variables ¶
View Source
var ErrContainerBlobNotExist = util.NewNotExistErrorf("container blob does not exist")
Functions ¶
func GetContainerBlob ¶
func GetContainerBlob(ctx context.Context, opts *BlobSearchOptions) (*packages.PackageFileDescriptor, error)
GetContainerBlob gets the container blob matching the blob search options If multiple matching blobs are found (manifests with the same digest) the first (according to the database) is selected.
func GetContainerBlobs ¶
func GetContainerBlobs(ctx context.Context, opts *BlobSearchOptions) ([]*packages.PackageFileDescriptor, error)
GetContainerBlobs gets the container blobs matching the blob search options
func GetImageTags ¶
func GetImageTags(ctx context.Context, ownerID int64, image string, n int, last string) ([]string, error)
GetImageTags gets a sorted list of the tags of an image The result is suitable for the api call.
func GetManifestVersions ¶
func GetManifestVersions(ctx context.Context, opts *BlobSearchOptions) ([]*packages.PackageVersion, error)
GetManifestVersions gets all package versions representing the matching manifest
func GetRepositories ¶
func GetRepositories(ctx context.Context, actor *user_model.User, n int, last string) ([]string, error)
GetRepositories gets a sorted list of all repositories
func SearchExpiredUploadedBlobs ¶
func SearchExpiredUploadedBlobs(ctx context.Context, olderThan time.Duration) ([]*packages.PackageFile, error)
SearchExpiredUploadedBlobs gets all uploaded blobs which are older than specified
func SearchImageTags ¶
func SearchImageTags(ctx context.Context, opts *ImageTagsSearchOptions) ([]*packages.PackageVersion, int64, error)
SearchImageTags gets a sorted list of the tags of an image
Types ¶
type BlobSearchOptions ¶
type ImageTagsSearchOptions ¶
Click to show internal directories.
Click to hide internal directories.