bs

package
v0.2.3 Latest Latest
Warning

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

Go to latest
Published: May 31, 2024 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExtractBsInfos

func ExtractBsInfos(m *machine.MachineInfos) map[uuid.UUID]*BlockStorageInfos

TODO maybe get block-storage type directly without check instead of this double check machine/bs ?

func OpenstackGetBlockStorage

func OpenstackGetBlockStorage(machineInfos *machine.MachineInfos) (map[uuid.UUID]*BlockStorageInfos, error)

Types

type BlockStorageInfos

type BlockStorageInfos struct {
	Uuid      uuid.UUID         `json:"uuid"`
	FullUuid  uuid.UUID         `json:"full_uuid"` // Some BS types truncate UUIDs (virtio_blk for example...)
	MachineId uuid.UUID         `json:"machine_id"`
	Size      int               `json:"size"` // Stored in Gi unit
	Device    string            `json:"device"`
	Type      string            `json:"type"`
	BlockDev  string            `json:"block_dev"`
	Status    string            `json:"status"`
	NodeName  string            `json:"node_name"`
	Metadata  map[string]string `json:"metadata"`
}

type MultiAttach added in v0.2.0

type MultiAttach struct {
	Count int               `json:"count"`
	Data  []OpenstackAttach `json:"data"`
}

type MultiAttachments added in v0.2.0

type MultiAttachments struct {
	NodeName    string      `json:"node_name"`
	MultiAttach MultiAttach `json:"multi-attach"`
}

func OpenstackGetMultiAttachments added in v0.2.0

func OpenstackGetMultiAttachments(machineInfos *machine.MachineInfos) (*MultiAttachments, error)

type OpenstackAttach added in v0.2.0

type OpenstackAttach struct {
	AttachmentId string `json:"attachment_id"`
	Device       string `json:"device"`
	HostName     string `json:"host_name"`
	ServerId     string `json:"server_id"`
	VolumeId     string `json:"volume_id"`
	NodeName     string `json:"node_name"`
}

Jump to

Keyboard shortcuts

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