Documentation ¶
Index ¶
- Constants
- type DeleteRepoImageOptions
- type DockerImagesRepo
- func (repo *DockerImagesRepo) CreateImageRepo(_ string) error
- func (repo *DockerImagesRepo) DeleteImageRepo(imageName string) error
- func (repo *DockerImagesRepo) DeleteRepo() error
- func (repo *DockerImagesRepo) DeleteRepoImage(_ DeleteRepoImageOptions, repoImageList ...*image.Info) error
- func (repo *DockerImagesRepo) GetAllImageRepoTags(imageName string) ([]string, error)
- func (repo *DockerImagesRepo) GetRepoImage(imageName, tag string) (*image.Info, error)
- func (repo *DockerImagesRepo) GetRepoImages(imageNames []string) (map[string][]*image.Info, error)
- func (m DockerImagesRepo) ImageRepo(imageName string) string
- func (m DockerImagesRepo) ImageRepoTag(imageName, tag string) string
- func (m DockerImagesRepo) ImageRepoWithTag(imageName, tag string) string
- func (repo *DockerImagesRepo) ImageRepositoryName(imageName string) string
- func (repo *DockerImagesRepo) ImageRepositoryNameWithTag(imageName, tag string) string
- func (repo *DockerImagesRepo) ImageRepositoryTag(imageName, tag string) string
- func (m DockerImagesRepo) ImagesRepo() string
- func (m DockerImagesRepo) IsMonorepo() bool
- func (repo *DockerImagesRepo) PublishImage(publishImage *container_runtime.WerfImage) error
- func (repo *DockerImagesRepo) RemoveImageRepo(_ string) error
- func (repo *DockerImagesRepo) String() string
- func (repo *DockerImagesRepo) Validate() error
- type DockerImagesRepoOptions
- type FileLockManager
- func (lockManager *FileLockManager) LockAllImagesReadOnly(projectName string) error
- func (lockManager *FileLockManager) LockImage(imageName string) error
- func (lockManager *FileLockManager) LockStage(projectName, signature string) error
- func (lockManager *FileLockManager) LockStageCache(projectName, signature string) error
- func (lockManager *FileLockManager) ReleaseAllStageLocks() error
- func (lockManager *FileLockManager) UnlockAllImages(projectName string) error
- func (lockManager *FileLockManager) UnlockImage(imageName string) error
- func (lockManager *FileLockManager) UnlockStage(projectName, signature string) error
- func (lockManager *FileLockManager) UnlockStageCache(projectName, signature string) error
- type FileStagesStorageCache
- type ImageInfosCacheData
- type ImagesRepo
- type ImagesRepoOptions
- type LocalDockerServerStagesStorage
- func (storage *LocalDockerServerStagesStorage) AddManagedImage(projectName, imageName string) error
- func (storage *LocalDockerServerStagesStorage) CleanupLocalImage(img container_runtime.Image) error
- func (storage *LocalDockerServerStagesStorage) ConstructStageImageName(projectName, signature, uniqueID string) string
- func (storage *LocalDockerServerStagesStorage) DeleteRepoImage(options DeleteRepoImageOptions, repoImageList ...*image.Info) error
- func (storage *LocalDockerServerStagesStorage) FetchImage(img container_runtime.Image) error
- func (storage *LocalDockerServerStagesStorage) GetImageInfo(projectName, signature, uniqueID string) (*image.Info, error)
- func (storage *LocalDockerServerStagesStorage) GetManagedImages(projectName string) ([]string, error)
- func (storage *LocalDockerServerStagesStorage) GetRepoImages(projectName string) ([]*image.Info, error)
- func (storage *LocalDockerServerStagesStorage) GetRepoImagesBySignature(projectName, signature string) ([]*image.Info, error)
- func (storage *LocalDockerServerStagesStorage) RmManagedImage(projectName, imageName string) error
- func (storage *LocalDockerServerStagesStorage) ShouldCleanupLocalImage(img container_runtime.Image) (bool, error)
- func (storage *LocalDockerServerStagesStorage) ShouldFetchImage(img container_runtime.Image) (bool, error)
- func (storage *LocalDockerServerStagesStorage) StoreImage(img container_runtime.Image) error
- func (storage *LocalDockerServerStagesStorage) String() string
- func (storage *LocalDockerServerStagesStorage) Validate() error
- type LockManager
- type RepoStagesStorage
- func (storage *RepoStagesStorage) AddManagedImage(projectName, imageName string) error
- func (storage *RepoStagesStorage) CleanupLocalImage(img container_runtime.Image) error
- func (storage *RepoStagesStorage) ConstructStageImageName(projectName, signature, uniqueID string) string
- func (storage *RepoStagesStorage) DeleteRepoImage(options DeleteRepoImageOptions, repoImageList ...*image.Info) error
- func (storage *RepoStagesStorage) FetchImage(img container_runtime.Image) error
- func (storage *RepoStagesStorage) GetImageInfo(projectName, signature, uniqueID string) (*image.Info, error)
- func (storage *RepoStagesStorage) GetManagedImages(projectName string) ([]string, error)
- func (storage *RepoStagesStorage) GetRepoImages(projectName string) ([]*image.Info, error)
- func (storage *RepoStagesStorage) GetRepoImagesBySignature(projectName, signature string) ([]*image.Info, error)
- func (storage *RepoStagesStorage) RmManagedImage(projectName, imageName string) error
- func (storage *RepoStagesStorage) ShouldCleanupLocalImage(img container_runtime.Image) (bool, error)
- func (storage *RepoStagesStorage) ShouldFetchImage(img container_runtime.Image) (bool, error)
- func (storage *RepoStagesStorage) StoreImage(img container_runtime.Image) error
- func (storage *RepoStagesStorage) String() string
- func (storage *RepoStagesStorage) Validate() error
- type RepoStagesStorageOptions
- type StagesStorage
- type StagesStorageCache
- type StagesStorageOptions
Constants ¶
View Source
const ( MultirepoImagesRepoMode = "multirepo" MonorepoImagesRepoMode = "monorepo" )
View Source
const ( LocalStage_ImageRepoPrefix = "werf-stages-storage/" LocalStage_ImageRepoFormat = "werf-stages-storage/%s" LocalStage_ImageFormat = "werf-stages-storage/%s:%s-%s" LocalManagedImageRecord_ImageNamePrefix = "werf-managed-images/" LocalManagedImageRecord_ImageNameFormat = "werf-managed-images/%s" LocalManagedImageRecord_ImageFormat = "werf-managed-images/%s:%s" )
View Source
const ( RepoStage_ImageTagFormat = "%s-%s" RepoStage_ImageFormat = "%s:%s-%s" RepoManagedImageRecord_ImageTagPrefix = "managed-image-" RepoManagedImageRecord_ImageTagFormat = "managed-image-%s" RepoManagedImageRecord_ImageNameFormat = "%s:managed-image-%s" )
View Source
const ( LocalStagesStorageAddress = ":local" NamelessImageRecordTag = "__nameless__" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DeleteRepoImageOptions ¶
type DockerImagesRepo ¶ added in v1.1.9
type DockerImagesRepo struct { docker_registry.DockerRegistry // contains filtered or unexported fields }
func (*DockerImagesRepo) CreateImageRepo ¶ added in v1.1.9
func (repo *DockerImagesRepo) CreateImageRepo(_ string) error
func (*DockerImagesRepo) DeleteImageRepo ¶ added in v1.1.9
func (repo *DockerImagesRepo) DeleteImageRepo(imageName string) error
func (*DockerImagesRepo) DeleteRepo ¶
func (repo *DockerImagesRepo) DeleteRepo() error
func (*DockerImagesRepo) DeleteRepoImage ¶ added in v1.1.9
func (repo *DockerImagesRepo) DeleteRepoImage(_ DeleteRepoImageOptions, repoImageList ...*image.Info) error
func (*DockerImagesRepo) GetAllImageRepoTags ¶ added in v1.1.9
func (repo *DockerImagesRepo) GetAllImageRepoTags(imageName string) ([]string, error)
func (*DockerImagesRepo) GetRepoImage ¶ added in v1.1.9
func (repo *DockerImagesRepo) GetRepoImage(imageName, tag string) (*image.Info, error)
func (*DockerImagesRepo) GetRepoImages ¶ added in v1.1.9
func (DockerImagesRepo) ImageRepoTag ¶ added in v1.1.9
func (DockerImagesRepo) ImageRepoWithTag ¶ added in v1.1.9
func (*DockerImagesRepo) ImageRepositoryName ¶ added in v1.1.9
func (repo *DockerImagesRepo) ImageRepositoryName(imageName string) string
func (*DockerImagesRepo) ImageRepositoryNameWithTag ¶ added in v1.1.9
func (repo *DockerImagesRepo) ImageRepositoryNameWithTag(imageName, tag string) string
func (*DockerImagesRepo) ImageRepositoryTag ¶ added in v1.1.9
func (repo *DockerImagesRepo) ImageRepositoryTag(imageName, tag string) string
func (DockerImagesRepo) ImagesRepo ¶ added in v1.1.9
func (m DockerImagesRepo) ImagesRepo() string
func (DockerImagesRepo) IsMonorepo ¶ added in v1.1.9
func (m DockerImagesRepo) IsMonorepo() bool
func (*DockerImagesRepo) PublishImage ¶ added in v1.1.9
func (repo *DockerImagesRepo) PublishImage(publishImage *container_runtime.WerfImage) error
FIXME: use docker-registry object
func (*DockerImagesRepo) RemoveImageRepo ¶
func (repo *DockerImagesRepo) RemoveImageRepo(_ string) error
func (*DockerImagesRepo) String ¶ added in v1.1.9
func (repo *DockerImagesRepo) String() string
func (*DockerImagesRepo) Validate ¶
func (repo *DockerImagesRepo) Validate() error
type DockerImagesRepoOptions ¶ added in v1.1.9
type DockerImagesRepoOptions struct { docker_registry.DockerRegistryOptions Implementation string }
type FileLockManager ¶
type FileLockManager struct {
// contains filtered or unexported fields
}
func (*FileLockManager) LockAllImagesReadOnly ¶
func (lockManager *FileLockManager) LockAllImagesReadOnly(projectName string) error
func (*FileLockManager) LockImage ¶
func (lockManager *FileLockManager) LockImage(imageName string) error
func (*FileLockManager) LockStage ¶
func (lockManager *FileLockManager) LockStage(projectName, signature string) error
func (*FileLockManager) LockStageCache ¶
func (lockManager *FileLockManager) LockStageCache(projectName, signature string) error
func (*FileLockManager) ReleaseAllStageLocks ¶
func (lockManager *FileLockManager) ReleaseAllStageLocks() error
func (*FileLockManager) UnlockAllImages ¶
func (lockManager *FileLockManager) UnlockAllImages(projectName string) error
func (*FileLockManager) UnlockImage ¶
func (lockManager *FileLockManager) UnlockImage(imageName string) error
func (*FileLockManager) UnlockStage ¶
func (lockManager *FileLockManager) UnlockStage(projectName, signature string) error
func (*FileLockManager) UnlockStageCache ¶
func (lockManager *FileLockManager) UnlockStageCache(projectName, signature string) error
type FileStagesStorageCache ¶
type FileStagesStorageCache struct {
CacheDir string
}
func NewFileStagesStorageCache ¶
func NewFileStagesStorageCache(cacheDir string) *FileStagesStorageCache
func (*FileStagesStorageCache) GetImagesBySignature ¶
func (*FileStagesStorageCache) StoreImagesBySignature ¶
func (cache *FileStagesStorageCache) StoreImagesBySignature(projectName, signature string, imagesDescs []*image.Info) error
type ImageInfosCacheData ¶
type ImagesRepo ¶ added in v1.1.9
type ImagesRepo interface { DeleteRepo() error DeleteImageRepo(imageName string) error GetRepoImage(imageName, tag string) (*image.Info, error) GetRepoImages(imageNames []string) (map[string][]*image.Info, error) DeleteRepoImage(_ DeleteRepoImageOptions, repoImageList ...*image.Info) error GetAllImageRepoTags(imageName string) ([]string, error) PublishImage(publishImage *container_runtime.WerfImage) error CreateImageRepo(imageName string) error RemoveImageRepo(imageName string) error ImageRepositoryName(imageName string) string ImageRepositoryNameWithTag(imageName, tag string) string ImageRepositoryTag(imageName, tag string) string Validate() error String() string }
func NewDockerImagesRepo ¶ added in v1.1.9
func NewDockerImagesRepo(projectName, imagesRepoAddress, imagesRepoMode string, options DockerImagesRepoOptions) (ImagesRepo, error)
func NewImagesRepo ¶ added in v1.1.9
func NewImagesRepo(projectName, imagesRepoAddress, imagesRepoMode string, options ImagesRepoOptions) (ImagesRepo, error)
type ImagesRepoOptions ¶ added in v1.1.9
type ImagesRepoOptions struct {
DockerImagesRepoOptions
}
type LocalDockerServerStagesStorage ¶ added in v1.1.9
type LocalDockerServerStagesStorage struct { // Local stages storage is compatible only with docker-server backed runtime LocalDockerServerRuntime *container_runtime.LocalDockerServerRuntime }
func NewLocalDockerServerStagesStorage ¶ added in v1.1.9
func NewLocalDockerServerStagesStorage(localDockerServerRuntime *container_runtime.LocalDockerServerRuntime) *LocalDockerServerStagesStorage
func (*LocalDockerServerStagesStorage) AddManagedImage ¶ added in v1.1.9
func (storage *LocalDockerServerStagesStorage) AddManagedImage(projectName, imageName string) error
func (*LocalDockerServerStagesStorage) CleanupLocalImage ¶
func (storage *LocalDockerServerStagesStorage) CleanupLocalImage(img container_runtime.Image) error
func (*LocalDockerServerStagesStorage) ConstructStageImageName ¶ added in v1.1.9
func (storage *LocalDockerServerStagesStorage) ConstructStageImageName(projectName, signature, uniqueID string) string
func (*LocalDockerServerStagesStorage) DeleteRepoImage ¶
func (storage *LocalDockerServerStagesStorage) DeleteRepoImage(options DeleteRepoImageOptions, repoImageList ...*image.Info) error
func (*LocalDockerServerStagesStorage) FetchImage ¶ added in v1.1.9
func (storage *LocalDockerServerStagesStorage) FetchImage(img container_runtime.Image) error
func (*LocalDockerServerStagesStorage) GetImageInfo ¶
func (storage *LocalDockerServerStagesStorage) GetImageInfo(projectName, signature, uniqueID string) (*image.Info, error)
func (*LocalDockerServerStagesStorage) GetManagedImages ¶ added in v1.1.9
func (storage *LocalDockerServerStagesStorage) GetManagedImages(projectName string) ([]string, error)
func (*LocalDockerServerStagesStorage) GetRepoImages ¶
func (storage *LocalDockerServerStagesStorage) GetRepoImages(projectName string) ([]*image.Info, error)
func (*LocalDockerServerStagesStorage) GetRepoImagesBySignature ¶
func (storage *LocalDockerServerStagesStorage) GetRepoImagesBySignature(projectName, signature string) ([]*image.Info, error)
func (*LocalDockerServerStagesStorage) RmManagedImage ¶ added in v1.1.9
func (storage *LocalDockerServerStagesStorage) RmManagedImage(projectName, imageName string) error
func (*LocalDockerServerStagesStorage) ShouldCleanupLocalImage ¶
func (storage *LocalDockerServerStagesStorage) ShouldCleanupLocalImage(img container_runtime.Image) (bool, error)
func (*LocalDockerServerStagesStorage) ShouldFetchImage ¶ added in v1.1.9
func (storage *LocalDockerServerStagesStorage) ShouldFetchImage(img container_runtime.Image) (bool, error)
func (*LocalDockerServerStagesStorage) StoreImage ¶ added in v1.1.9
func (storage *LocalDockerServerStagesStorage) StoreImage(img container_runtime.Image) error
func (*LocalDockerServerStagesStorage) String ¶ added in v1.1.9
func (storage *LocalDockerServerStagesStorage) String() string
func (*LocalDockerServerStagesStorage) Validate ¶
func (storage *LocalDockerServerStagesStorage) Validate() error
type LockManager ¶
type LockManager interface { LockStage(projectName, signature string) error UnlockStage(projectName, signature string) error LockStageCache(projectName, signature string) error UnlockStageCache(projectName, signature string) error LockImage(imageName string) error UnlockImage(imageName string) error }
type RepoStagesStorage ¶ added in v1.1.9
type RepoStagesStorage struct { RepoAddress string DockerRegistry docker_registry.DockerRegistry ContainerRuntime container_runtime.ContainerRuntime }
func NewRepoStagesStorage ¶ added in v1.1.9
func NewRepoStagesStorage(repoAddress string, containerRuntime container_runtime.ContainerRuntime, options RepoStagesStorageOptions) (*RepoStagesStorage, error)
func (*RepoStagesStorage) AddManagedImage ¶ added in v1.1.9
func (storage *RepoStagesStorage) AddManagedImage(projectName, imageName string) error
func (*RepoStagesStorage) CleanupLocalImage ¶
func (storage *RepoStagesStorage) CleanupLocalImage(img container_runtime.Image) error
func (*RepoStagesStorage) ConstructStageImageName ¶ added in v1.1.9
func (storage *RepoStagesStorage) ConstructStageImageName(projectName, signature, uniqueID string) string
func (*RepoStagesStorage) DeleteRepoImage ¶
func (storage *RepoStagesStorage) DeleteRepoImage(options DeleteRepoImageOptions, repoImageList ...*image.Info) error
func (*RepoStagesStorage) FetchImage ¶ added in v1.1.9
func (storage *RepoStagesStorage) FetchImage(img container_runtime.Image) error
func (*RepoStagesStorage) GetImageInfo ¶
func (storage *RepoStagesStorage) GetImageInfo(projectName, signature, uniqueID string) (*image.Info, error)
func (*RepoStagesStorage) GetManagedImages ¶ added in v1.1.9
func (storage *RepoStagesStorage) GetManagedImages(projectName string) ([]string, error)
func (*RepoStagesStorage) GetRepoImages ¶
func (storage *RepoStagesStorage) GetRepoImages(projectName string) ([]*image.Info, error)
func (*RepoStagesStorage) GetRepoImagesBySignature ¶
func (storage *RepoStagesStorage) GetRepoImagesBySignature(projectName, signature string) ([]*image.Info, error)
func (*RepoStagesStorage) RmManagedImage ¶ added in v1.1.9
func (storage *RepoStagesStorage) RmManagedImage(projectName, imageName string) error
func (*RepoStagesStorage) ShouldCleanupLocalImage ¶
func (storage *RepoStagesStorage) ShouldCleanupLocalImage(img container_runtime.Image) (bool, error)
func (*RepoStagesStorage) ShouldFetchImage ¶ added in v1.1.9
func (storage *RepoStagesStorage) ShouldFetchImage(img container_runtime.Image) (bool, error)
func (*RepoStagesStorage) StoreImage ¶ added in v1.1.9
func (storage *RepoStagesStorage) StoreImage(img container_runtime.Image) error
func (*RepoStagesStorage) String ¶ added in v1.1.9
func (storage *RepoStagesStorage) String() string
func (*RepoStagesStorage) Validate ¶
func (storage *RepoStagesStorage) Validate() error
type RepoStagesStorageOptions ¶ added in v1.1.9
type RepoStagesStorageOptions struct { docker_registry.DockerRegistryOptions Implementation string }
type StagesStorage ¶
type StagesStorage interface { GetRepoImages(projectName string) ([]*image.Info, error) DeleteRepoImage(options DeleteRepoImageOptions, repoImageList ...*image.Info) error GetRepoImagesBySignature(projectName, signature string) ([]*image.Info, error) ConstructStageImageName(projectName, signature, uniqueID string) string GetImageInfo(projectName, signature, uniqueID string) (*image.Info, error) // FetchImage will create a local image in the container-runtime FetchImage(img container_runtime.Image) error // StoreImage will store a local image into the container-runtime, local built image should exist prior running store StoreImage(img container_runtime.Image) error // CleanupLocalImage will remove a local image from container-runtime CleanupLocalImage(img container_runtime.Image) error ShouldFetchImage(img container_runtime.Image) (bool, error) ShouldCleanupLocalImage(img container_runtime.Image) (bool, error) AddManagedImage(projectName, imageName string) error RmManagedImage(projectName, imageName string) error GetManagedImages(projectName string) ([]string, error) Validate() error String() string }
func NewStagesStorage ¶ added in v1.1.9
func NewStagesStorage(stagesStorageAddress string, containerRuntime container_runtime.ContainerRuntime, options StagesStorageOptions) (StagesStorage, error)
type StagesStorageCache ¶
type StagesStorageOptions ¶ added in v1.1.9
type StagesStorageOptions struct {
RepoStagesStorageOptions
}
Click to show internal directories.
Click to hide internal directories.