storageplanner

package
v0.22.0 Latest Latest
Warning

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

Go to latest
Published: Apr 16, 2026 License: AGPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TransportTypeSATA = "sata"
	TransportTypeNVMe = "nvme"
)

Variables

This section is empty.

Functions

func GenerateStoragePlan

func GenerateStoragePlan(ctx context.Context, serverID string,

	commandExecutor commandexecutor.CommandExecutor,

	osSize,
	zfsPoolSize int,
) (*storageplan.StoragePlan, error)

Generates storage plan for the intended server.

Types

type LSBLKOutput

type LSBLKOutput struct {
	BlockDevices []LSBLKOutputRow `json:"blockdevices"`
}

type LSBLKOutputRow

type LSBLKOutputRow struct {
	Name string `json:"name"`
	WWN  string `json:"wwn"`
	Size int    `json:"size"`

	RotationalDevice   bool   `json:"rota"`
	TransportType      string `json:"tran"`
	PartitionTableType string `json:"pttype"`
}

REFER : https://github.com/util-linux/util-linux/blob/4a4eb88f263bfffeee75cfcabcb6e364ef5900a3/misc-utils/lsblk.c#L174.

func (*LSBLKOutputRow) GetDiskType

func (l *LSBLKOutputRow) GetDiskType() string

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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