Documentation
¶
Index ¶
- func New() resource.Driver
- type T
- func (t *T) Abort(ctx context.Context) bool
- func (t *T) ContainerHead(ctx context.Context) (string, error)
- func (t *T) EncapCmd(ctx context.Context, args []string, envs []string, stdin io.Reader) (resource.Commander, error)
- func (t *T) EncapCp(ctx context.Context, src, dst string) error
- func (t *T) Enter(ctx context.Context) error
- func (t *T) GetHostname() string
- func (t *T) GetOsvcRootPath() string
- func (t *T) Label(_ context.Context) string
- func (t *T) LinkNames() []string
- func (t *T) Manifest() *manifest.T
- func (t *T) NetNSPath(ctx context.Context) (string, error)
- func (t *T) PID(ctx context.Context) int
- func (t *T) ProvisionAsLeader(ctx context.Context) error
- func (t *T) Provisioned(ctx context.Context) (provisioned.T, error)
- func (t *T) SetEncapFileOwnership(ctx context.Context, p string) error
- func (t *T) Signal(ctx context.Context, sig syscall.Signal) error
- func (t *T) Start(ctx context.Context) error
- func (t *T) Status(ctx context.Context) status.T
- func (t *T) Stop(ctx context.Context) error
- func (t *T) ToSync(ctx context.Context) []string
- func (t *T) Unprovision(ctx context.Context) error
- func (t *T) UnprovisionAsFollower(ctx context.Context) error
- func (t *T) UnprovisionAsLeader(ctx context.Context) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type T ¶
type T struct {
resource.T
resource.SSH
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) ContainerHead ¶
ContainerHead implements the interface replacing b2.1 the zonepath resource attribute
func (*T) GetHostname ¶
func (*T) GetOsvcRootPath ¶
func (*T) Label ¶
Label implements Label from resource.Driver interface, it returns a formatted short description of the Resource
func (*T) LinkNames ¶
LinkNames implements the interface necessary for the container.lxc resources to be targeted by ip.cni, ip.netns, ...
func (*T) NetNSPath ¶
NetNSPath implements the resource.NetNSPather optional interface. Used by ip.netns and ip.route to configure network stuff in the container.
func (*T) PID ¶
PID implements the resource.PIDer optional interface. Used by ip.netns to name the veth pair devices.
func (*T) Provisioned ¶
func (*T) SetEncapFileOwnership ¶
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.