Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ExportImage ¶ added in v0.0.3
ExportImage uses crane to export an image to a tarball It is basically the same code as crane export https://github.com/google/go-containerregistry/blob/a0658aa1d0cc7a7f1bcc4a3af9155335b6943f40/cmd/crane/cmd/export.go#L55
This is different from image downloader because that appears to download the manifest and individual blobs.
func ParseImageList ¶
ParseImageList attempts to initialize an ImageList object from the supplied path
func ReconcileFile ¶ added in v0.0.2
ReconcileFile reconciles the images defined in a set of files. It is a helper function primarily used by the CLI
Types ¶
type Controller ¶ added in v0.0.2
type Controller struct {
// contains filtered or unexported fields
}
Controller for images. A controller is capable of building images and resolving images to shas.
func NewController ¶ added in v0.0.2
func NewController() (*Controller, error)
func (*Controller) Reconcile ¶ added in v0.0.2
Reconcile an image. This will build the image if necessary and resolve the image to a sha. Status is updated with status about the image. basePath is the basePath to resolve paths against
func (*Controller) SetLocalRepos ¶ added in v0.0.3
func (c *Controller) SetLocalRepos(repos []GitRepoRef) error
SetLocalRepos sets the local repositories to use when resolving images
type Extractor ¶
Extractor extracts the URLs of all the docker images in a directory of manifests
type GitRepoRef ¶ added in v0.0.3
type GitRepoRef struct { Repo *git.Repository W *git.Worktree }
GitRepoRef is a reference to a git repository. TODO(jeremy): Is this neccessary? Can we retrieve the Repo from the work tree? I don't think we want to always reconstruct the workTree from gitRepos because that could be expensive in particular updating the ignore patterns is expensive.
type ImageDownloader ¶
type ImageDownloader struct { Log logr.Logger ImageList v1alpha1.ImageList ImageDir string SkipIfFileExists bool DummyDownload bool }
ImageDownloader handles pulling images given ImageList
func (*ImageDownloader) DownloadImagesWithRetry ¶
func (d *ImageDownloader) DownloadImagesWithRetry(retry int) error
DownloadImagesWithRetry calls DownloadImagesToDir, retrying if errors occur
type ImageUploader ¶
ImageUploader handles upload images to target Repo given image dir
func (*ImageUploader) UploadImagesWithRetry ¶
func (u *ImageUploader) UploadImagesWithRetry(retry int) (imageMappings []images.ImageMapping, err error)
UploadImagesWithRetry calls UploadImagesFromDir, retrying if errors occur