Documentation ¶
Index ¶
- func GetSortedVersions(storage StorageAdapter, artifactSpec core.ArtifactSpec) ([]*semver.Version, error)
- func Tidy(storage StorageAdapter, artifactSpec core.ArtifactSpec, keep int, ...) error
- type LocalDirectoryAdapter
- func (a *LocalDirectoryAdapter) DeleteVersion(spec core.ArtifactVersionSpec) error
- func (a *LocalDirectoryAdapter) Download(ctx context.Context, spec core.ArtifactVersionSpec, target echo.Context) error
- func (a *LocalDirectoryAdapter) GetVersions(artifactSpec core.ArtifactSpec) ([]*semver.Version, error)
- func (a *LocalDirectoryAdapter) Upload(ctx context.Context, spec core.ArtifactVersionSpec, echo echo.Context, ...) error
- type MinioAdapter
- func (a *MinioAdapter) DeleteVersion(spec core.ArtifactVersionSpec) error
- func (a *MinioAdapter) Download(ctx context.Context, spec core.ArtifactVersionSpec, target echo.Context) error
- func (a *MinioAdapter) GetVersions(artifactSpec core.ArtifactSpec) ([]*semver.Version, error)
- func (a *MinioAdapter) Upload(ctx context.Context, spec core.ArtifactVersionSpec, target echo.Context, ...) error
- type StorageAdapter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetSortedVersions ¶
func GetSortedVersions(storage StorageAdapter, artifactSpec core.ArtifactSpec) ([]*semver.Version, error)
func Tidy ¶
func Tidy(storage StorageAdapter, artifactSpec core.ArtifactSpec, keep int, belowVersion *core.ArtifactVersionSpec) error
Types ¶
type LocalDirectoryAdapter ¶
type LocalDirectoryAdapter struct {
// contains filtered or unexported fields
}
func LocalDirectory ¶
func LocalDirectory() *LocalDirectoryAdapter
func (*LocalDirectoryAdapter) DeleteVersion ¶
func (a *LocalDirectoryAdapter) DeleteVersion(spec core.ArtifactVersionSpec) error
func (*LocalDirectoryAdapter) Download ¶
func (a *LocalDirectoryAdapter) Download(ctx context.Context, spec core.ArtifactVersionSpec, target echo.Context) error
func (*LocalDirectoryAdapter) GetVersions ¶
func (a *LocalDirectoryAdapter) GetVersions(artifactSpec core.ArtifactSpec) ([]*semver.Version, error)
func (*LocalDirectoryAdapter) Upload ¶
func (a *LocalDirectoryAdapter) Upload(ctx context.Context, spec core.ArtifactVersionSpec, echo echo.Context, source io.Reader) error
type MinioAdapter ¶
type MinioAdapter struct {
// contains filtered or unexported fields
}
func MinIO ¶
func MinIO() *MinioAdapter
func (*MinioAdapter) DeleteVersion ¶
func (a *MinioAdapter) DeleteVersion(spec core.ArtifactVersionSpec) error
func (*MinioAdapter) Download ¶
func (a *MinioAdapter) Download(ctx context.Context, spec core.ArtifactVersionSpec, target echo.Context) error
func (*MinioAdapter) GetVersions ¶
func (a *MinioAdapter) GetVersions(artifactSpec core.ArtifactSpec) ([]*semver.Version, error)
func (*MinioAdapter) Upload ¶
func (a *MinioAdapter) Upload(ctx context.Context, spec core.ArtifactVersionSpec, target echo.Context, source io.Reader) error
type StorageAdapter ¶
type StorageAdapter interface { Upload(ctx context.Context, spec core.ArtifactVersionSpec, target echo.Context, source io.Reader) error Download(ctx context.Context, spec core.ArtifactVersionSpec, target echo.Context) error GetVersions(artifactSpec core.ArtifactSpec) ([]*semver.Version, error) DeleteVersion(spec core.ArtifactVersionSpec) error }
Click to show internal directories.
Click to hide internal directories.