sysinit

package
v0.4.31 Latest Latest
Warning

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

Go to latest
Published: May 15, 2020 License: GPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BlockDevice added in v0.4.30

type BlockDevice struct {
	Name     string         `json:"name"`
	FsType   string         `json:"fstype"`
	Children []*BlockDevice `json:"children"`
}

func ListBlockDevices added in v0.4.30

func ListBlockDevices(ctx context.Context) ([]*BlockDevice, error)

type Config

type Config struct {
	// Device name with Docker partition, for example "/dev/sda2".
	Device string `yaml:"device"`
	// Cipher type.
	Cipher string `yaml:"cipher"`
	// Filesystem type.
	FsType string `yaml:"fs_type"`
	// Where to mount the encrypted Docker partition.
	MountPoint string `yaml:"mount_point"`
}

type CreateEncryptedVolumeAction

type CreateEncryptedVolumeAction struct {
	Name     string
	Password string
	Device   string
	Cipher   string
}

func (*CreateEncryptedVolumeAction) Execute

func (*CreateEncryptedVolumeAction) Rollback

func (m *CreateEncryptedVolumeAction) Rollback() error

type CreateFileSystemAction added in v0.4.30

type CreateFileSystemAction struct {
	Name   string
	Type   string
	Device string
}

func (*CreateFileSystemAction) Execute added in v0.4.30

func (m *CreateFileSystemAction) Execute(ctx context.Context) error

func (*CreateFileSystemAction) Rollback added in v0.4.30

func (m *CreateFileSystemAction) Rollback() error

type CreateMountPointAction

type CreateMountPointAction struct {
	MountPoint string
	Perm       os.FileMode
}

func (*CreateMountPointAction) Execute

func (m *CreateMountPointAction) Execute(ctx context.Context) error

func (*CreateMountPointAction) Rollback

func (m *CreateMountPointAction) Rollback() error

type FailAction

type FailAction struct{}

func (*FailAction) Execute

func (m *FailAction) Execute(ctx context.Context) error

func (*FailAction) Rollback

func (m *FailAction) Rollback() error

type InitService

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

func NewInitService

func NewInitService(cfg *Config, log *zap.SugaredLogger) *InitService

func (*InitService) Mount

func (m *InitService) Mount(ctx context.Context, request *sonm.InitMountRequest) (*sonm.InitMountResponse, error)

func (*InitService) Reset

func (m *InitService) Reset(ctx context.Context)

type MountDeviceMapperAction

type MountDeviceMapperAction struct {
	Name       string
	MountPoint string
	Type       string
	Options    string
}

func (*MountDeviceMapperAction) Execute

func (m *MountDeviceMapperAction) Execute(ctx context.Context) error

func (*MountDeviceMapperAction) Rollback

func (m *MountDeviceMapperAction) Rollback() error

type StartDockerAction

type StartDockerAction struct {
}

func (*StartDockerAction) Execute

func (m *StartDockerAction) Execute(ctx context.Context) error

func (*StartDockerAction) Rollback

func (m *StartDockerAction) Rollback() error

Jump to

Keyboard shortcuts

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