Documentation ¶
Index ¶
- Variables
- func NewRegistryConfig(m map[string]config.RegistryConfig) docker.RegistryHosts
- type Pool
- type ResolveMode
- type Resolver
- func (r *Resolver) Fetcher(ctx context.Context, ref string) (remotes.Fetcher, error)
- func (r *Resolver) HostsFunc(host string) ([]docker.RegistryHost, error)
- func (r *Resolver) Resolve(ctx context.Context, ref string) (string, ocispecs.Descriptor, error)
- func (r *Resolver) WithImageStore(is images.Store, mode ResolveMode) *Resolver
- func (r *Resolver) WithSession(s session.Group) *Resolver
Constants ¶
This section is empty.
Variables ¶
View Source
var DefaultPool = NewPool()
DefaultPool is the default shared resolver pool instance
Functions ¶
func NewRegistryConfig ¶
func NewRegistryConfig(m map[string]config.RegistryConfig) docker.RegistryHosts
NewRegistryConfig converts registry config to docker.RegistryHosts callback
Types ¶
type Pool ¶
type Pool struct {
// contains filtered or unexported fields
}
Pool is a cache of recently used resolvers
type ResolveMode ¶
type ResolveMode int
const ( ResolveModeDefault ResolveMode = iota ResolveModeForcePull ResolveModePreferLocal )
func ParseImageResolveMode ¶
func ParseImageResolveMode(v string) (ResolveMode, error)
func (ResolveMode) String ¶
func (r ResolveMode) String() string
type Resolver ¶
Resolver is a wrapper around remotes.Resolver
func (*Resolver) HostsFunc ¶
func (r *Resolver) HostsFunc(host string) ([]docker.RegistryHost, error)
HostsFunc implements registry configuration of this Resolver
func (*Resolver) WithImageStore ¶
func (r *Resolver) WithImageStore(is images.Store, mode ResolveMode) *Resolver
WithImageStore returns new resolver that can also resolve from local images store
Click to show internal directories.
Click to hide internal directories.