Documentation ¶
Index ¶
- Constants
- Variables
- func FetchError(context, registry, reponame string, err error) error
- func Verify(r io.Reader, d digest.Digest) (io.ReadCloser, int64, error)
- type CompositeFetcher
- type ContainerIDProvider
- type Dialer
- type FetchLock
- type FetchRequest
- type Image
- type ImageRetainer
- type LayerIDProvider
- type Local
- type Lock
- type Registry
- type Remote
- type RemoteFetcher
- type RemoteImageIDFetcher
- type RepositoryFetcher
- type Retryable
- type Verifier
- type VerifyFunc
Constants ¶
View Source
const MAX_ATTEMPTS = 3
Variables ¶
View Source
var DefaultVerifier = VerifyFunc(Verify)
View Source
var ErrInvalidDockerURL = errors.New("invalid docker url")
View Source
var RegistryNewEndpoint = registry.NewEndpoint
apes dockers registry.NewEndpoint
View Source
var RegistryNewSession = registry.NewSession
apes dockers registry.NewSession
Functions ¶
func FetchError ¶
func Verify ¶
Verify reads the given reader in to a temporary file and validates that it matches the digest. If it does, it returns a reader for that allows access to the data. Otherwise, it returns an error. The caller is responsible for closing the returned reader, in order to ensure the temporary file is deleted.
Types ¶
type CompositeFetcher ¶
type CompositeFetcher struct { // fetcher used for requests without a scheme LocalFetcher RepositoryFetcher // fetchers used for docker:// urls, depending on the version RemoteFetcher RepositoryFetcher }
type ContainerIDProvider ¶
type FetchLock ¶
type FetchLock struct {
// contains filtered or unexported fields
}
func NewFetchLock ¶
func NewFetchLock() *FetchLock
type FetchRequest ¶
type ImageRetainer ¶
type ImageRetainer struct { DirectoryRootfsIDProvider ContainerIDProvider DockerImageIDFetcher RemoteImageIDFetcher GraphRetainer layercake.Retainer NamespaceCacheKey string Logger lager.Logger }
func (*ImageRetainer) Retain ¶
func (i *ImageRetainer) Retain(imageList []string)
type LayerIDProvider ¶
type LayerIDProvider struct { }
type Local ¶
type Local struct { Cake layercake.Cake DefaultRootFSPath string IDProvider ContainerIDProvider // contains filtered or unexported fields }
type Registry ¶
type Registry interface { // v1 methods GetRepositoryData(repoName string) (*registry.RepositoryData, error) GetRemoteTags(registries []string, repository string) (map[string]string, error) GetRemoteHistory(imageID string, registry string) ([]string, error) GetRemoteImageJSON(imageID string, registry string) ([]byte, int, error) GetRemoteImageLayer(imageID string, registry string, size int64) (io.ReadCloser, error) }
apes docker's *registry.Registry
type Remote ¶
type Remote struct { DefaultHost string Dial Dialer Cake layercake.Cake Verifier Verifier FetchLock *FetchLock }
type RemoteFetcher ¶
type RemoteFetcher interface {
Fetch(request *FetchRequest) (*Image, error)
}
type RemoteImageIDFetcher ¶
type RepositoryFetcher ¶
Source Files ¶
Directories ¶
Path | Synopsis |
---|---|
Code generated by counterfeiter.
|
Code generated by counterfeiter. |
Code generated by counterfeiter.
|
Code generated by counterfeiter. |
This file was generated by counterfeiter
|
This file was generated by counterfeiter |
This file was generated by counterfeiter
|
This file was generated by counterfeiter |
Code generated by counterfeiter.
|
Code generated by counterfeiter. |
Click to show internal directories.
Click to hide internal directories.