rescontainerdocker

package
v0.0.0-...-63b02d4 Latest Latest
Warning

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

Go to latest
Published: Apr 18, 2024 License: Apache-2.0 Imports: 39 Imported by: 0

Documentation

Index

Constants

View Source
const (
	AlwaysPolicy = "always"
	OncePolicy   = "once"
)

Variables

This section is empty.

Functions

func New

func New() resource.Driver

Types

type T

type T struct {
	resource.T
	resource.SCSIPersistentReservation
	PG              pg.Config      `json:"pg"`
	Path            naming.Path    `json:"path"`
	ObjectID        uuid.UUID      `json:"object_id"`
	SCSIReserv      bool           `json:"scsireserv"`
	PromoteRW       bool           `json:"promote_rw"`
	NoPreemptAbort  bool           `json:"no_preempt_abort"`
	OsvcRootPath    string         `json:"osvc_root_path"`
	GuestOS         string         `json:"guest_os"`
	Name            string         `json:"name"`
	Hostname        string         `json:"hostname"`
	Image           string         `json:"image"`
	ImagePullPolicy string         `json:"image_pull_policy"`
	CWD             string         `json:"cwd"`
	User            string         `json:"user"`
	Command         []string       `json:"command"`
	DNS             []string       `json:"dns"`
	DNSSearch       []string       `json:"dns_search"`
	RunArgs         []string       `json:"run_args"`
	Entrypoint      []string       `json:"entrypoint"`
	Detach          bool           `json:"detach"`
	Remove          bool           `json:"remove"`
	Privileged      bool           `json:"privileged"`
	Init            bool           `json:"init"`
	Interactive     bool           `json:"interactive"`
	TTY             bool           `json:"tty"`
	VolumeMounts    []string       `json:"volume_mounts"`
	Env             []string       `json:"environment"`
	SecretsEnv      []string       `json:"secrets_environment"`
	ConfigsEnv      []string       `json:"configs_environment"`
	Devices         []string       `json:"devices"`
	NetNS           string         `json:"netns"`
	UserNS          string         `json:"userns"`
	PIDNS           string         `json:"pidns"`
	IPCNS           string         `json:"ipcns"`
	UTSNS           string         `json:"utsns"`
	RegistryCreds   string         `json:"registry_creds"`
	PullTimeout     *time.Duration `json:"pull_timeout"`
	StartTimeout    *time.Duration `json:"start_timeout"`
	StopTimeout     *time.Duration `json:"stop_timeout"`
}

func (*T) Configure

func (t *T) Configure() error

func (T) ContainerName

func (t T) ContainerName() string

ContainerName formats a docker container name

func (T) Enter

func (t T) Enter() error

func (T) Inspect

func (t T) Inspect(ctx context.Context) (containerapi.ContainerInspect, error)

func (T) Label

func (t T) Label() string

func (T) LinkNames

func (t T) LinkNames() []string

func (T) Manifest

func (t T) Manifest() *manifest.T

Manifest exposes to the core the input expected by the driver.

func (*T) NetNSPath

func (t *T) NetNSPath() (string, error)

NetNSPath implements the resource.NetNSPather optional interface. Used by ip.netns and ip.route to configure network stuff in the container.

func (*T) PID

func (t *T) PID() int

PID implements the resource.PIDer optional interface. Used by ip.netns to name the veth pair devices.

func (T) Provision

func (t T) Provision(ctx context.Context) error

func (T) Provisioned

func (t T) Provisioned() (provisioned.T, error)

func (T) Signal

func (t T) Signal(sig syscall.Signal) error

func (T) Start

func (t T) Start(ctx context.Context) error

func (*T) Status

func (t *T) Status(ctx context.Context) status.T

func (T) Stop

func (t T) Stop(ctx context.Context) error

func (T) Unprovision

func (t T) Unprovision(ctx context.Context) error

Jump to

Keyboard shortcuts

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