rescontainerlxc

package
v0.0.0-...-3f873ad Latest Latest
Warning

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

Go to latest
Published: Dec 10, 2024 License: Apache-2.0 Imports: 38 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New() resource.Driver

Types

type T

type T struct {
	resource.T
	resource.SCSIPersistentReservation
	Path                     naming.Path    `json:"path"`
	ObjectID                 uuid.UUID      `json:"object_id"`
	Nodes                    []string       `json:"nodes"`
	DNS                      []string       `json:"dns"`
	SCSIReserv               bool           `json:"scsireserv"`
	PromoteRW                bool           `json:"promote_rw"`
	OsvcRootPath             string         `json:"osvc_root_path"`
	GuestOS                  string         `json:"guest_os"`
	Name                     string         `json:"name"`
	Hostname                 string         `json:"hostname"`
	DataDir                  string         `json:"data_dir"`
	RootDir                  string         `json:"root_dir"`
	ConfigFile               string         `json:"cf"`
	Template                 string         `json:"template"`
	TemplateOptions          []string       `json:"template_options"`
	CreateSecretsEnvironment []string       `json:"create_secrets_environment"`
	CreateConfigsEnvironment []string       `json:"create_configs_environment"`
	CreateEnvironment        []string       `json:"create_environment"`
	RCmd                     []string       `json:"rcmd"`
	StartTimeout             *time.Duration `json:"start_timeout"`
	StopTimeout              *time.Duration `json:"stop_timeout"`
	// contains filtered or unexported fields
}

func (*T) Abort

func (t *T) Abort(ctx context.Context) bool

func (*T) ContainerHead

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

ContainerHead implements the interface replacing b2.1 the zonepath resource attribute

func (T) Enter

func (t T) Enter() error

func (T) Label

func (t T) Label() string

func (T) LinkNames

func (t T) LinkNames() []string

LinkNames implements the interface necessary for the container.lxc resources to be targeted by ip.cni, ip.netns, ...

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) ProvisionLeader

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

func (T) Provisioned

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

func (*T) SetEncapFileOwnership

func (t *T) SetEncapFileOwnership(p string) error

SetEncapFileOwnership sets the ownership of the file to be the same ownership than the container root dir, which may be not root for unprivileged containers.

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) ToSync

func (t T) ToSync() []string

func (T) Unprovision

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

func (*T) UnprovisionLeaded

func (t *T) UnprovisionLeaded(ctx context.Context) error

func (*T) UnprovisionLeader

func (t *T) UnprovisionLeader(ctx context.Context) error

Jump to

Keyboard shortcuts

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