Documentation
¶
Index ¶
- func ExtractCred(cfg AuthConfig, registry string) (user, pass string, err error)
- func ParseAuthFile(path, registry string) (string, string, error)
- type Attach
- type AuthConfig
- type AuthConfigEntry
- type Build
- type Extract
- type Fetch
- type Inspect
- type Login
- type Prune
- type Pull
- type PullHooks
- type Push
- type Root
- type Upload
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ExtractCred ¶
func ExtractCred(cfg AuthConfig, registry string) (user, pass string, err error)
Types ¶
type Attach ¶
type AuthConfig ¶
type AuthConfig struct {
Auths map[string]AuthConfigEntry `json:"auths"`
}
AuthConfig is a structure for dockerconfigjson‑style files.
type AuthConfigEntry ¶
type AuthConfigEntry struct {
Username string `json:"username,omitempty"`
Password string `json:"password,omitempty"`
Auth string `json:"auth,omitempty"`
}
AuthConfigEntry holds authentication credentials for a registry.
type Build ¶
type Extract ¶
func NewExtract ¶
func NewExtract() *Extract
type Fetch ¶
type Inspect ¶
func NewInspect ¶
func NewInspect() *Inspect
type Login ¶
type Pull ¶
type PullHooks ¶
type PullHooks interface {
// BeforePullLayer will execute before pulling the layer described as desc,
// will carry the manifest as well.
//
// If the hook returns skip=true, the backend will treat this layer as
// already satisfied and will NOT actually pull/extract it. The caller is
// responsible for ensuring the corresponding content already exists and
// matches the descriptor's digest. AfterPullLayer will still be invoked
// with skipped=true and a nil error.
BeforePullLayer(desc ocispec.Descriptor, manifest ocispec.Manifest) (skip bool)
// AfterPullLayer will execute after pulling the layer described as desc.
// skipped indicates whether the layer was skipped by BeforePullLayer's
// decision. err will be nil if pulled (or skipped) successfully.
AfterPullLayer(desc ocispec.Descriptor, skipped bool, err error)
}
PullHooks is the hook events during the pull operation.
Note: every retry attempt re-invokes BeforePullLayer / AfterPullLayer.
Source Files
¶
Click to show internal directories.
Click to hide internal directories.