Documentation ¶
Overview ¶
+k8s:deepcopy-gen=package +groupName=harvesterhci.io
+k8s:deepcopy-gen=package +groupName=harvesterhci.io
+k8s:deepcopy-gen=package +groupName=harvesterhci.io
Index ¶
- Variables
- func Kind(kind string) schema.GroupKind
- func Resource(resource string) schema.GroupResource
- type BlockDevice
- type BlockDeviceList
- type BlockDeviceProvisionPhase
- type BlockDeviceSpec
- type BlockDeviceState
- type BlockDeviceStatus
- type BlockDeviceType
- type Condition
- type DeviceCapcity
- type DeviceDetails
- type DeviceStatus
- type DriveType
- type FilesystemInfo
- type FilesystemStatus
- type StorageController
Constants ¶
This section is empty.
Variables ¶
var ( DeviceMounted condition.Cond = "Mounted" DeviceFormatting condition.Cond = "Formatting" DiskAddedToNode condition.Cond = "AddedToNode" )
var ( SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) AddToScheme = SchemeBuilder.AddToScheme )
var (
BlockDeviceResourceName = "blockdevices"
)
var SchemeGroupVersion = schema.GroupVersion{Group: harvesterhci.GroupName, Version: "v1beta1"}
SchemeGroupVersion is group version used to register these objects
Functions ¶
func Resource ¶
func Resource(resource string) schema.GroupResource
Resource takes an unqualified resource and returns a Group qualified GroupResource
Types ¶
type BlockDevice ¶
type BlockDevice struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata"` Spec BlockDeviceSpec `json:"spec"` Status BlockDeviceStatus `json:"status"` }
func NewBlockDevice ¶
func NewBlockDevice(namespace, name string, obj BlockDevice) *BlockDevice
func (*BlockDevice) DeepCopy ¶
func (in *BlockDevice) DeepCopy() *BlockDevice
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BlockDevice.
func (*BlockDevice) DeepCopyInto ¶
func (in *BlockDevice) DeepCopyInto(out *BlockDevice)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*BlockDevice) DeepCopyObject ¶
func (in *BlockDevice) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type BlockDeviceList ¶
type BlockDeviceList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata"` Items []BlockDevice `json:"items"` }
BlockDeviceList is a list of BlockDevice resources
func (*BlockDeviceList) DeepCopy ¶
func (in *BlockDeviceList) DeepCopy() *BlockDeviceList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BlockDeviceList.
func (*BlockDeviceList) DeepCopyInto ¶
func (in *BlockDeviceList) DeepCopyInto(out *BlockDeviceList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*BlockDeviceList) DeepCopyObject ¶
func (in *BlockDeviceList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type BlockDeviceProvisionPhase ¶ added in v0.4.0
type BlockDeviceProvisionPhase string
const ( // ProvisionPhaseProvisioned indicates the block device is in provision. ProvisionPhaseProvisioned BlockDeviceProvisionPhase = "Provisioned" // ProvisionPhaseUnprovisioning indicates the block device is being unprovisioned. ProvisionPhaseUnprovisioning BlockDeviceProvisionPhase = "Unprovisioning" // ProvisionPhaseUnprovisioned indicates the block device is not in provision. ProvisionPhaseUnprovisioned BlockDeviceProvisionPhase = "Unprovisioned" )
type BlockDeviceSpec ¶
type BlockDeviceSpec struct { // name of the node to which the block device is attached // +kubebuilder:validation:Required NodeName string `json:"nodeName"` // a string with the device path of the disk, e.g. "/dev/sda1" // +kubebuilder:validation:Required DevPath string `json:"devPath"` FileSystem *FilesystemInfo `json:"fileSystem"` }
func (*BlockDeviceSpec) DeepCopy ¶
func (in *BlockDeviceSpec) DeepCopy() *BlockDeviceSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BlockDeviceSpec.
func (*BlockDeviceSpec) DeepCopyInto ¶
func (in *BlockDeviceSpec) DeepCopyInto(out *BlockDeviceSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type BlockDeviceState ¶
type BlockDeviceState string
const ( // BlockDeviceActive is the state for a block device that is connected to the node BlockDeviceActive BlockDeviceState = "Active" // BlockDeviceInactive is the state for a block device that is disconnected from a node BlockDeviceInactive BlockDeviceState = "Inactive" // BlockDeviceUnknown is the state for a block device that cannot be determined at this time BlockDeviceUnknown BlockDeviceState = "Unknown" )
type BlockDeviceStatus ¶
type BlockDeviceStatus struct { // the current state of the block device, options are "Active", "Inactive", or "Unknown" // +kubebuilder:validation:Enum:=Active;Inactive;Unknown State BlockDeviceState `json:"state"` // The current phase of the block device being provisioned. // +kubebuilder:validation:Enum:=Provisioned;Unprovisioned;Unprovisioning // +kubebuilder:default:=Unprovisioned ProvisionPhase BlockDeviceProvisionPhase `json:"provisionPhase"` // +optional Conditions []Condition `json:"conditions,omitempty"` // +optional DeviceStatus DeviceStatus `json:"deviceStatus,omitempty"` }
func (*BlockDeviceStatus) DeepCopy ¶
func (in *BlockDeviceStatus) DeepCopy() *BlockDeviceStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BlockDeviceStatus.
func (*BlockDeviceStatus) DeepCopyInto ¶
func (in *BlockDeviceStatus) DeepCopyInto(out *BlockDeviceStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type BlockDeviceType ¶
type BlockDeviceType string
const ( // DeviceTypeDisk indicates the device type is disk DeviceTypeDisk BlockDeviceType = "disk" // DeviceTypePart indicates the device type is partition DeviceTypePart BlockDeviceType = "part" )
type Condition ¶
type Condition struct { // Type of the condition. Type condition.Cond `json:"type"` // Status of the condition, one of True, False, Unknown. Status v1.ConditionStatus `json:"status"` // The last time this condition was updated. LastUpdateTime string `json:"lastUpdateTime,omitempty"` // Last time the condition transitioned from one status to another. LastTransitionTime string `json:"lastTransitionTime,omitempty"` // The reason for the condition's last transition. Reason string `json:"reason,omitempty"` // Human-readable message indicating details about last transition Message string `json:"message,omitempty"` }
func (*Condition) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Condition.
func (*Condition) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type DeviceCapcity ¶
type DeviceCapcity struct { // the amount of storage the disk provides SizeBytes uint64 `json:"sizeBytes"` // the size of the physical blocks used on the disk, in bytes PhysicalBlockSizeBytes uint64 `json:"physicalBlockSizeBytes"` }
func (*DeviceCapcity) DeepCopy ¶
func (in *DeviceCapcity) DeepCopy() *DeviceCapcity
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DeviceCapcity.
func (*DeviceCapcity) DeepCopyInto ¶
func (in *DeviceCapcity) DeepCopyInto(out *DeviceCapcity)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type DeviceDetails ¶
type DeviceDetails struct { // a string represents the type of the device, options are "disk", "part" // +kubebuilder:validation:Enum:=disk;part DeviceType BlockDeviceType `json:"deviceType"` // a string represents the type of drive bus, options are "HDD", "FDD", "ODD", or "SSD", // which correspond to a hard disk drive (rotational), floppy drive, optical (CD/DVD) drive and solid-state drive // +kubebuilder:validation:Enum:=HDD;FDD;ODD;SSD;Unknown DriveType string `json:"driveType"` // PartUUID is a partition-table-level UUID for the partition, a standard feature for all partitions on GPT-partitioned disks PartUUID string `json:"partUUID,omitempty"` // UUID is a filesystem-level UUID, which is retrieved from the filesystem metadata inside the partition // This would be volume UUID on macOS, PartUUID on linux, empty on Windows UUID string `json:"uuid,omitempty"` // PtUUID is the UUID of the partition table itself, a unique identifier for the entire disk assigned at the time the disk was partitioned PtUUID string `json:"ptUUID,omitempty"` // contains a boolean indicating if the disk drive is removable IsRemovable bool `json:"isRemovable,omitempty"` // the type of storage controller/drive, options are "SCSI", "IDE", "virtio", "MMC", or "NVMe" // +kubebuilder:validation:Enum:=SCSI;IDE;virtio;MMC;NVMe;Unknown StorageController string `json:"storageController"` // a string represents the block device bus path BusPath string `json:"busPath,omitempty"` // a string with the vendor-assigned disk model name Model string `json:"model,omitempty"` // a string with the name of the hardware vendor for the disk drive Vendor string `json:"vendor,omitempty"` // a string with the disk's serial number SerialNumber string `json:"serialNumber,omitempty"` // the numeric index of the NUMA node this disk is local to, or -1 NUMANodeID int `json:"numaNodeID,omitempty"` // a string with the disk's World Wide Name(WWN) WWN string `json:"wwn,omitempty"` // a string containing the disk label Label string `json:"label,omitempty"` }
func (*DeviceDetails) DeepCopy ¶
func (in *DeviceDetails) DeepCopy() *DeviceDetails
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DeviceDetails.
func (*DeviceDetails) DeepCopyInto ¶
func (in *DeviceDetails) DeepCopyInto(out *DeviceDetails)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type DeviceStatus ¶
type DeviceStatus struct { // a string with the parent device path of the disk, e.g. "/dev/sda" // e.g `/dev/sda` is the parent for `/dev/sda1` ParentDevice string `json:"parentDevice,omitempty"` // a bool indicating if the disk is partitioned Partitioned bool `json:"partitioned"` // a object describe the disk capacity Capacity DeviceCapcity `json:"capacity"` // a object describe the disk details Details DeviceDetails `json:"details"` // device path DevPath string `json:"devPath"` FileSystem *FilesystemStatus `json:"fileSystem"` }
func (*DeviceStatus) DeepCopy ¶
func (in *DeviceStatus) DeepCopy() *DeviceStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DeviceStatus.
func (*DeviceStatus) DeepCopyInto ¶
func (in *DeviceStatus) DeepCopyInto(out *DeviceStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type DriveType ¶
type DriveType string
const ( // DriveTypeHDD is the type of drive, which correspond to a hard disk drive (rotational) DriveTypeHDD DriveType = "HDD" // DriveTypeFDD is the type of drive, which correspond to floppy drive DriveTypeFDD DriveType = "FDD" // DriveTypeODD is the type of drive, which correspond to optical (CD/DVD) drive DriveTypeODD DriveType = "ODD" // DriveTypeSSD is the type of drive, which correspond to solid-state drive DriveTypeSSD DriveType = "SSD" )
type FilesystemInfo ¶
type FilesystemInfo struct { // DEPRECATED: no longer use and has no effect. // a string with the partition's mount point, or "" if no mount point was discovered MountPoint string `json:"mountPoint"` // a bool indicating the device is force formatted to overwrite the existing one ForceFormatted bool `json:"forceFormatted,omitempty"` // a bool indicating whether the filesystem can be provisioned as a disk for the node to store data. Provisioned bool `json:"provisioned,omitempty"` // a bool indicating whether the filesystem is manually repaired of not Repaired bool `json:"repaired,omitempty"` }
func (*FilesystemInfo) DeepCopy ¶
func (in *FilesystemInfo) DeepCopy() *FilesystemInfo
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FilesystemInfo.
func (*FilesystemInfo) DeepCopyInto ¶
func (in *FilesystemInfo) DeepCopyInto(out *FilesystemInfo)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type FilesystemStatus ¶
type FilesystemStatus struct { // a bool indicating the partition is read-only IsReadOnly bool `json:"isReadOnly,omitempty"` // a string indicated the filesystem type for the partition, or "" if the system could not determine the type. Type string `json:"type"` // a string with the partition's mount point, or "" if no mount point was discovered MountPoint string `json:"mountPoint"` // the last force formatted timestamp, only exist when user operate device formatting through the CRD controller LastFormattedAt *metav1.Time `json:"LastFormattedAt,omitempty"` // indicating whether the filesystem is corrupted or not Corrupted bool `json:"corrupted,omitempty"` }
func (*FilesystemStatus) DeepCopy ¶
func (in *FilesystemStatus) DeepCopy() *FilesystemStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FilesystemStatus.
func (*FilesystemStatus) DeepCopyInto ¶
func (in *FilesystemStatus) DeepCopyInto(out *FilesystemStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type StorageController ¶
type StorageController string
const ( // StorageControllerIDE is the type of storage controller, IDE stands for Integrated Drive Electronics StorageControllerIDE StorageController = "IDE" // StorageControllerSCSI is the type of storage controller, SCSI stands for Small Computer System Interface StorageControllerSCSI StorageController = "SCSI" // StorageControllerNVMe is the type of storage controller, NVMe stands for Non-Volatile Memory express StorageControllerNVMe StorageController = "NVMe" // StorageControllerVirtio is the type of storage controller, virtio is a virtualization standard for network and disk device drivers StorageControllerVirtio StorageController = "virtio" // StorageControllerMMC is the type of storage controller, MMC stands for Multi Media Card StorageControllerMMC StorageController = "MMC" )