clustvirt/lib/storagepool/lib.go

55 lines
1.0 KiB
Go

// Package storagepool provides utilities and data structures in relation to storage pools.
// This library uses the libvirt and libvirtxml packages from libvirt.org to implement
// wrappers on top of the base library
package storagepool
import (
// log "git.staur.ca/stobbsm/simplelog"
// "github.com/gofrs/uuid/v5"
"libvirt.org/go/libvirt"
// "libvirt.org/go/libvirtxml"
)
var StoragePoolStateMap = map[libvirt.StoragePoolState]string{
libvirt.STORAGE_POOL_INACTIVE: "inactive",
libvirt.STORAGE_POOL_BUILDING: "building",
libvirt.STORAGE_POOL_RUNNING: "running",
libvirt.STORAGE_POOL_DEGRADED: "degraded",
libvirt.STORAGE_POOL_INACCESSIBLE: "inaccessible",
}
var Types = []string{
"dir",
"fs",
"netfs",
"disk",
"iscsi",
"logical",
"scsi",
"mpath",
"rbd",
"sheepdog",
"gluster",
"zfs",
"iscsi-direct",
}
var LocalTypes = []string{
"dir",
"fs",
"disk",
"logical",
"scsi",
"zfs",
}
var NetTypes = []string{
"netfs",
"iscsi",
"mpath",
"rbd",
"sheepdog",
"gluster",
"iscsi-direct",
}