cache

package
v0.5.61 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 12, 2024 License: MPL-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const TypeImageCache string = "image_cache"

TypeImageCache is the resource string for a ImageCache resource

View Source
const TypeRegistry string = "container_registry"

Variables

This section is empty.

Functions

This section is empty.

Types

type ImageCache

type ImageCache struct {
	// embedded type holding name, etc
	types.ResourceMetadata `hcl:",remain"`

	Registries []Registry `hcl:"registry,block" json:"registries,omitempty"`

	Networks ctypes.NetworkAttachments `hcl:"network,block" json:"networks,omitempty"` // Attach to the correct network // only when Image is specified
}

ImageCache defines a structure for creating ImageCache containers

type Provider

type Provider struct {
	// contains filtered or unexported fields
}

func (*Provider) Changed

func (p *Provider) Changed() (bool, error)

func (*Provider) Create

func (p *Provider) Create() error

func (*Provider) Destroy

func (p *Provider) Destroy() error

func (*Provider) Init

func (p *Provider) Init(cfg htypes.Resource, l sdk.Logger) error

func (*Provider) Lookup

func (p *Provider) Lookup() ([]string, error)

func (*Provider) Refresh

func (p *Provider) Refresh() error

Refresh is called whenever any Network resources are added or removed in Shipyard this is because we need to ensure that the cache is attached to all networks so that it can work with any clusters that may be on those networks.

type Registry added in v0.5.60

type Registry struct {
	// embedded type holding name, etc
	types.ResourceMetadata `hcl:",remain"`

	Hostname string        `hcl:"hostname" json:"hostname"`         // Hostname of the registry
	Auth     *RegistryAuth `hcl:"auth,block" json:"auth,omitempty"` // auth to authenticate against registry
}

Registry defines a structure for registering additional registries for the image cache

type RegistryAuth added in v0.5.60

type RegistryAuth struct {
	Hostname string `hcl:"hostname,optional" json:"hostname,omitempty"` // Hostname for authentication, can be different from registry hostname
	Username string `hcl:"username" json:"username"`                    // Username for authentication
	Password string `hcl:"password" json:"password"`                    // Password for authentication
}

RegistryAuth defines a structure for authenticating against a docker registry

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL