Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BasicAuthTransport ¶
type Credentials ¶
type Credentials struct { Username string `json:"username"` Password string `json:"password"` Email string `json:"email"` Auth string `json:"auth"` }
Credentials is a structure to unmarshall .dockercfg data
type Registry ¶
type Registry struct { Name string // contains filtered or unexported fields }
Registry is a docker registry with `Name` and private `credentials`
func NewRegistry ¶
func NewRegistry(name string, credentials *Credentials) (r *Registry, err error)
NewRegistry create a new registry with given name and credentials and configure http client
func (*Registry) Get ¶
func (r *Registry) Get(pathTemplate string, args ...interface{}) (response *http.Response, err error)
Get makes GET API call for given path with auth headers
type RegistryList ¶
type RegistryList struct {
Items []*Registry
}
func GetRegistries ¶
func GetRegistries(k *client.Client, deployment *ext.Deployment) (registries *RegistryList, err error)
GetRegistries returns list of registries based on deployment's image pull secrets
type Repository ¶
Repository is an image repository in a registry
func NewRepository ¶
func NewRepository(image string, registry *Registry) *Repository
NewRepository return a new Repository for given image name
func (*Repository) GetLatestVersion ¶
func (r *Repository) GetLatestVersion(filter semver.Range) (version *Version, err error)
GetLatestVersion returns the latest image version based on tag
type Version ¶
Image version with repository tag and semver representation. `Tag` shoulf be used to get image by its tag. `Semver` is for version compare. TODO make it consistent, changing one field should affect another
func NewVersion ¶
NewVersion return association for image tag and its semver