v1alpha1

package
v0.5.0-rc.1 Latest Latest
Warning

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

Go to latest
Published: Aug 12, 2019 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Overview

+k8s:deepcopy-gen=package +k8s:defaulter-gen=TypeMeta +k8s:openapi-gen=true +k8s:conversion-gen=github.com/weaveworks/ignite/pkg/apis/ignite

Index

Constants

View Source
const (
	KindImage  meta.Kind = "Image"
	KindKernel meta.Kind = "Kernel"
	KindVM     meta.Kind = "VM"
)
View Source
const (
	// GroupName is the group name use in this package
	GroupName = "ignite.weave.works"
)

Variables

View Source
var (
	// SchemeBuilder the schema builder
	SchemeBuilder = runtime.NewSchemeBuilder(
		addKnownTypes,
		addDefaultingFuncs,
	)

	AddToScheme = localSchemeBuilder.AddToScheme
)
View Source
var SchemeGroupVersion = schema.GroupVersion{
	Group:   GroupName,
	Version: "v1alpha1",
}

SchemeGroupVersion is group version used to register these objects

Functions

func Convert_ignite_FileMapping_To_v1alpha1_FileMapping added in v0.5.0

func Convert_ignite_FileMapping_To_v1alpha1_FileMapping(in *ignite.FileMapping, out *FileMapping, s conversion.Scope) error

Convert_ignite_FileMapping_To_v1alpha1_FileMapping is an autogenerated conversion function.

func Convert_ignite_ImageSpec_To_v1alpha1_ImageSpec added in v0.5.0

func Convert_ignite_ImageSpec_To_v1alpha1_ImageSpec(in *ignite.ImageSpec, out *ImageSpec, s conversion.Scope) error

Convert_ignite_ImageSpec_To_v1alpha1_ImageSpec calls the autogenerated conversion function along with custom conversion logic

func Convert_ignite_ImageStatus_To_v1alpha1_ImageStatus added in v0.5.0

func Convert_ignite_ImageStatus_To_v1alpha1_ImageStatus(in *ignite.ImageStatus, out *ImageStatus, s conversion.Scope) error

Convert_ignite_ImageStatus_To_v1alpha1_ImageStatus is an autogenerated conversion function.

func Convert_ignite_Image_To_v1alpha1_Image added in v0.5.0

func Convert_ignite_Image_To_v1alpha1_Image(in *ignite.Image, out *Image, s conversion.Scope) error

Convert_ignite_Image_To_v1alpha1_Image is an autogenerated conversion function.

func Convert_ignite_KernelSpec_To_v1alpha1_KernelSpec added in v0.5.0

func Convert_ignite_KernelSpec_To_v1alpha1_KernelSpec(in *ignite.KernelSpec, out *KernelSpec, s conversion.Scope) error

Convert_ignite_KernelSpec_To_v1alpha1_KernelSpec calls the autogenerated conversion function along with custom conversion logic

func Convert_ignite_KernelStatus_To_v1alpha1_KernelStatus added in v0.5.0

func Convert_ignite_KernelStatus_To_v1alpha1_KernelStatus(in *ignite.KernelStatus, out *KernelStatus, s conversion.Scope) error

Convert_ignite_KernelStatus_To_v1alpha1_KernelStatus is an autogenerated conversion function.

func Convert_ignite_Kernel_To_v1alpha1_Kernel added in v0.5.0

func Convert_ignite_Kernel_To_v1alpha1_Kernel(in *ignite.Kernel, out *Kernel, s conversion.Scope) error

Convert_ignite_Kernel_To_v1alpha1_Kernel is an autogenerated conversion function.

func Convert_ignite_OCIImageSource_To_v1alpha1_OCIImageSource added in v0.5.0

func Convert_ignite_OCIImageSource_To_v1alpha1_OCIImageSource(in *ignite.OCIImageSource, out *OCIImageSource, s conversion.Scope) error

Convert_ignite_OCIImageSource_To_v1alpha1_OCIImageSource calls the autogenerated conversion function along with custom conversion logic

func Convert_ignite_OCI_To_v1alpha1_OCIClaim added in v0.5.0

func Convert_ignite_OCI_To_v1alpha1_OCIClaim(in *meta.OCIImageRef, out *OCIImageClaim) error

func Convert_ignite_PoolDevice_To_v1alpha1_PoolDevice added in v0.5.0

func Convert_ignite_PoolDevice_To_v1alpha1_PoolDevice(in *ignite.PoolDevice, out *PoolDevice, s conversion.Scope) error

Convert_ignite_PoolDevice_To_v1alpha1_PoolDevice is an autogenerated conversion function.

func Convert_ignite_PoolSpec_To_v1alpha1_PoolSpec added in v0.5.0

func Convert_ignite_PoolSpec_To_v1alpha1_PoolSpec(in *ignite.PoolSpec, out *PoolSpec, s conversion.Scope) error

Convert_ignite_PoolSpec_To_v1alpha1_PoolSpec is an autogenerated conversion function.

func Convert_ignite_PoolStatus_To_v1alpha1_PoolStatus added in v0.5.0

func Convert_ignite_PoolStatus_To_v1alpha1_PoolStatus(in *ignite.PoolStatus, out *PoolStatus, s conversion.Scope) error

Convert_ignite_PoolStatus_To_v1alpha1_PoolStatus is an autogenerated conversion function.

func Convert_ignite_Pool_To_v1alpha1_Pool added in v0.5.0

func Convert_ignite_Pool_To_v1alpha1_Pool(in *ignite.Pool, out *Pool, s conversion.Scope) error

Convert_ignite_Pool_To_v1alpha1_Pool is an autogenerated conversion function.

func Convert_ignite_SSH_To_v1alpha1_SSH added in v0.5.0

func Convert_ignite_SSH_To_v1alpha1_SSH(in *ignite.SSH, out *SSH, s conversion.Scope) error

Convert_ignite_SSH_To_v1alpha1_SSH is an autogenerated conversion function.

func Convert_ignite_VMImageSpec_To_v1alpha1_VMImageSpec added in v0.5.0

func Convert_ignite_VMImageSpec_To_v1alpha1_VMImageSpec(in *ignite.VMImageSpec, out *VMImageSpec, s conversion.Scope) error

Convert_ignite_VMImageSpec_To_v1alpha1_VMImageSpec calls the autogenerated conversion function along with custom conversion logic

func Convert_ignite_VMKernelSpec_To_v1alpha1_VMKernelSpec added in v0.5.0

func Convert_ignite_VMKernelSpec_To_v1alpha1_VMKernelSpec(in *ignite.VMKernelSpec, out *VMKernelSpec, s conversion.Scope) error

Convert_ignite_VMKernelSpec_To_v1alpha1_VMKernelSpec calls the autogenerated conversion function along with custom conversion logic

func Convert_ignite_VMNetworkSpec_To_v1alpha1_VMNetworkSpec added in v0.5.0

func Convert_ignite_VMNetworkSpec_To_v1alpha1_VMNetworkSpec(in *ignite.VMNetworkSpec, out *VMNetworkSpec, s conversion.Scope) error

Convert_ignite_VMNetworkSpec_To_v1alpha1_VMNetworkSpec is an autogenerated conversion function.

func Convert_ignite_VMSpec_To_v1alpha1_VMSpec added in v0.5.0

func Convert_ignite_VMSpec_To_v1alpha1_VMSpec(in *ignite.VMSpec, out *VMSpec, s conversion.Scope) error

Convert_ignite_VMSpec_To_v1alpha1_VMSpec calls the autogenerated conversion function along with custom conversion logic

func Convert_ignite_VMStatus_To_v1alpha1_VMStatus added in v0.5.0

func Convert_ignite_VMStatus_To_v1alpha1_VMStatus(in *ignite.VMStatus, out *VMStatus, s conversion.Scope) error

Convert_ignite_VMStatus_To_v1alpha1_VMStatus calls the autogenerated conversion function along with custom conversion logic

func Convert_ignite_VM_To_v1alpha1_VM added in v0.5.0

func Convert_ignite_VM_To_v1alpha1_VM(in *ignite.VM, out *VM, s conversion.Scope) error

Convert_ignite_VM_To_v1alpha1_VM is an autogenerated conversion function.

func Convert_v1alpha1_FileMapping_To_ignite_FileMapping added in v0.5.0

func Convert_v1alpha1_FileMapping_To_ignite_FileMapping(in *FileMapping, out *ignite.FileMapping, s conversion.Scope) error

Convert_v1alpha1_FileMapping_To_ignite_FileMapping is an autogenerated conversion function.

func Convert_v1alpha1_ImageSpec_To_ignite_ImageSpec added in v0.5.0

func Convert_v1alpha1_ImageSpec_To_ignite_ImageSpec(in *ImageSpec, out *ignite.ImageSpec, s conversion.Scope) error

Convert_v1alpha1_ImageSpec_To_ignite_ImageSpec calls the autogenerated conversion function along with custom conversion logic

func Convert_v1alpha1_ImageStatus_To_ignite_ImageStatus added in v0.5.0

func Convert_v1alpha1_ImageStatus_To_ignite_ImageStatus(in *ImageStatus, out *ignite.ImageStatus, s conversion.Scope) error

Convert_v1alpha1_ImageStatus_To_ignite_ImageStatus is an autogenerated conversion function.

func Convert_v1alpha1_Image_To_ignite_Image added in v0.5.0

func Convert_v1alpha1_Image_To_ignite_Image(in *Image, out *ignite.Image, s conversion.Scope) error

Convert_v1alpha1_Image_To_ignite_Image is an autogenerated conversion function.

func Convert_v1alpha1_KernelSpec_To_ignite_KernelSpec added in v0.5.0

func Convert_v1alpha1_KernelSpec_To_ignite_KernelSpec(in *KernelSpec, out *ignite.KernelSpec, s conversion.Scope) error

Convert_v1alpha1_KernelSpec_To_ignite_KernelSpec calls the autogenerated conversion function along with custom conversion logic

func Convert_v1alpha1_KernelStatus_To_ignite_KernelStatus added in v0.5.0

func Convert_v1alpha1_KernelStatus_To_ignite_KernelStatus(in *KernelStatus, out *ignite.KernelStatus, s conversion.Scope) error

Convert_v1alpha1_KernelStatus_To_ignite_KernelStatus is an autogenerated conversion function.

func Convert_v1alpha1_Kernel_To_ignite_Kernel added in v0.5.0

func Convert_v1alpha1_Kernel_To_ignite_Kernel(in *Kernel, out *ignite.Kernel, s conversion.Scope) error

Convert_v1alpha1_Kernel_To_ignite_Kernel is an autogenerated conversion function.

func Convert_v1alpha1_OCIClaim_To_ignite_OCI added in v0.5.0

func Convert_v1alpha1_OCIClaim_To_ignite_OCI(in *OCIImageClaim, out *meta.OCIImageRef) error

func Convert_v1alpha1_OCIImageSource_To_ignite_OCIImageSource added in v0.5.0

func Convert_v1alpha1_OCIImageSource_To_ignite_OCIImageSource(in *OCIImageSource, out *ignite.OCIImageSource, s conversion.Scope) (err error)

Convert_v1alpha1_OCIImageSource_To_ignite_OCIImageSource calls the autogenerated conversion function along with custom conversion logic

func Convert_v1alpha1_PoolDevice_To_ignite_PoolDevice added in v0.5.0

func Convert_v1alpha1_PoolDevice_To_ignite_PoolDevice(in *PoolDevice, out *ignite.PoolDevice, s conversion.Scope) error

Convert_v1alpha1_PoolDevice_To_ignite_PoolDevice is an autogenerated conversion function.

func Convert_v1alpha1_PoolSpec_To_ignite_PoolSpec added in v0.5.0

func Convert_v1alpha1_PoolSpec_To_ignite_PoolSpec(in *PoolSpec, out *ignite.PoolSpec, s conversion.Scope) error

Convert_v1alpha1_PoolSpec_To_ignite_PoolSpec is an autogenerated conversion function.

func Convert_v1alpha1_PoolStatus_To_ignite_PoolStatus added in v0.5.0

func Convert_v1alpha1_PoolStatus_To_ignite_PoolStatus(in *PoolStatus, out *ignite.PoolStatus, s conversion.Scope) error

Convert_v1alpha1_PoolStatus_To_ignite_PoolStatus is an autogenerated conversion function.

func Convert_v1alpha1_Pool_To_ignite_Pool added in v0.5.0

func Convert_v1alpha1_Pool_To_ignite_Pool(in *Pool, out *ignite.Pool, s conversion.Scope) error

Convert_v1alpha1_Pool_To_ignite_Pool is an autogenerated conversion function.

func Convert_v1alpha1_SSH_To_ignite_SSH added in v0.5.0

func Convert_v1alpha1_SSH_To_ignite_SSH(in *SSH, out *ignite.SSH, s conversion.Scope) error

Convert_v1alpha1_SSH_To_ignite_SSH is an autogenerated conversion function.

func Convert_v1alpha1_VMImageSpec_To_ignite_VMImageSpec added in v0.5.0

func Convert_v1alpha1_VMImageSpec_To_ignite_VMImageSpec(in *VMImageSpec, out *ignite.VMImageSpec, s conversion.Scope) error

Convert_v1alpha1_VMImageSpec_To_ignite_VMImageSpec calls the autogenerated conversion function along with custom conversion logic

func Convert_v1alpha1_VMKernelSpec_To_ignite_VMKernelSpec added in v0.5.0

func Convert_v1alpha1_VMKernelSpec_To_ignite_VMKernelSpec(in *VMKernelSpec, out *ignite.VMKernelSpec, s conversion.Scope) error

Convert_v1alpha1_VMKernelSpec_To_ignite_VMKernelSpec calls the autogenerated conversion function along with custom conversion logic

func Convert_v1alpha1_VMNetworkSpec_To_ignite_VMNetworkSpec added in v0.5.0

func Convert_v1alpha1_VMNetworkSpec_To_ignite_VMNetworkSpec(in *VMNetworkSpec, out *ignite.VMNetworkSpec, s conversion.Scope) error

Convert_v1alpha1_VMNetworkSpec_To_ignite_VMNetworkSpec calls the autogenerated conversion function and custom conversion logic

func Convert_v1alpha1_VMSpec_To_ignite_VMSpec added in v0.5.0

func Convert_v1alpha1_VMSpec_To_ignite_VMSpec(in *VMSpec, out *ignite.VMSpec, s conversion.Scope) error

Convert_ignite_VMSpec_To_v1alpha1_VMSpec calls the autogenerated conversion function along with custom conversion logic

func Convert_v1alpha1_VMStatus_To_ignite_VMStatus added in v0.5.0

func Convert_v1alpha1_VMStatus_To_ignite_VMStatus(in *VMStatus, out *ignite.VMStatus, s conversion.Scope) error

Convert_v1alpha1_VMStatus_To_ignite_VMStatus calls the autogenerated conversion function along with custom conversion logic

func Convert_v1alpha1_VM_To_ignite_VM added in v0.5.0

func Convert_v1alpha1_VM_To_ignite_VM(in *VM, out *ignite.VM, s conversion.Scope) error

Convert_v1alpha1_VM_To_ignite_VM is an autogenerated conversion function.

func RegisterConversions added in v0.5.0

func RegisterConversions(s *runtime.Scheme) error

RegisterConversions adds conversion functions to the given scheme. Public to allow building arbitrary schemes.

func RegisterDefaults

func RegisterDefaults(scheme *runtime.Scheme) error

RegisterDefaults adds defaulters functions to the given scheme. Public to allow building arbitrary schemes. All generated defaulters are covering - they call all nested defaulters.

func SetDefaults_OCIImageClaim

func SetDefaults_OCIImageClaim(obj *OCIImageClaim)

func SetDefaults_PoolSpec

func SetDefaults_PoolSpec(obj *PoolSpec)

func SetDefaults_VMKernelSpec

func SetDefaults_VMKernelSpec(obj *VMKernelSpec)

func SetDefaults_VMNetworkSpec

func SetDefaults_VMNetworkSpec(obj *VMNetworkSpec)

func SetDefaults_VMSpec

func SetDefaults_VMSpec(obj *VMSpec)

func SetDefaults_VMStatus

func SetDefaults_VMStatus(obj *VMStatus)

func SetObjectDefaults_Image

func SetObjectDefaults_Image(in *Image)

func SetObjectDefaults_Kernel

func SetObjectDefaults_Kernel(in *Kernel)

func SetObjectDefaults_Pool

func SetObjectDefaults_Pool(in *Pool)

func SetObjectDefaults_VM

func SetObjectDefaults_VM(in *VM)

Types

type FileMapping

type FileMapping struct {
	HostPath string `json:"hostPath"`
	VMPath   string `json:"vmPath"`
}

FileMapping defines mappings between files on the host and VM

func (*FileMapping) DeepCopy

func (in *FileMapping) DeepCopy() *FileMapping

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FileMapping.

func (*FileMapping) DeepCopyInto

func (in *FileMapping) DeepCopyInto(out *FileMapping)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Image

type Image struct {
	meta.TypeMeta `json:",inline"`
	// meta.ObjectMeta is also embedded into the struct, and defines the human-readable name, and the machine-readable ID
	// Name is available at the .metadata.name JSON path
	// ID is available at the .metadata.uid JSON path (the Go type is k8s.io/apimachinery/pkg/types.UID, which is only a typed string)
	meta.ObjectMeta `json:"metadata"`

	Spec   ImageSpec   `json:"spec"`
	Status ImageStatus `json:"status"`
}

Image represents a cached OCI image ready to be used with Ignite +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

func (*Image) DeepCopy

func (in *Image) DeepCopy() *Image

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Image.

func (*Image) DeepCopyInto

func (in *Image) DeepCopyInto(out *Image)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Image) DeepCopyObject

func (in *Image) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type ImageSourceType

type ImageSourceType string

ImageSourceType is an enum of different supported Image Source Types

const (
	// ImageSourceTypeDocker defines that the image is imported from Docker
	ImageSourceTypeDocker ImageSourceType = "Docker"
)

type ImageSpec

type ImageSpec struct {
	OCIClaim OCIImageClaim `json:"ociClaim"`
}

ImageSpec declares what the image contains

func (*ImageSpec) DeepCopy

func (in *ImageSpec) DeepCopy() *ImageSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ImageSpec.

func (*ImageSpec) DeepCopyInto

func (in *ImageSpec) DeepCopyInto(out *ImageSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ImageStatus

type ImageStatus struct {
	// OCISource contains the information about how this OCI image was imported
	OCISource OCIImageSource `json:"ociSource"`
}

ImageStatus defines the status of the image

func (*ImageStatus) DeepCopy

func (in *ImageStatus) DeepCopy() *ImageStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ImageStatus.

func (*ImageStatus) DeepCopyInto

func (in *ImageStatus) DeepCopyInto(out *ImageStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Kernel

type Kernel struct {
	meta.TypeMeta `json:",inline"`
	// meta.ObjectMeta is also embedded into the struct, and defines the human-readable name, and the machine-readable ID
	// Name is available at the .metadata.name JSON path
	// ID is available at the .metadata.uid JSON path (the Go type is k8s.io/apimachinery/pkg/types.UID, which is only a typed string)
	meta.ObjectMeta `json:"metadata"`

	Spec   KernelSpec   `json:"spec"`
	Status KernelStatus `json:"status"`
}

Kernel is a serializable object that caches information about imported kernels This file is stored in /var/lib/firecracker/kernels/{oci-image-digest}/metadata.json +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

func (*Kernel) DeepCopy

func (in *Kernel) DeepCopy() *Kernel

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Kernel.

func (*Kernel) DeepCopyInto

func (in *Kernel) DeepCopyInto(out *Kernel)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Kernel) DeepCopyObject

func (in *Kernel) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type KernelSpec

type KernelSpec struct {
	OCIClaim OCIImageClaim `json:"ociClaim"`
}

KernelSpec describes the properties of a kernel

func (*KernelSpec) DeepCopy

func (in *KernelSpec) DeepCopy() *KernelSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KernelSpec.

func (*KernelSpec) DeepCopyInto

func (in *KernelSpec) DeepCopyInto(out *KernelSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type KernelStatus

type KernelStatus struct {
	Version   string         `json:"version"`
	OCISource OCIImageSource `json:"ociSource"`
}

KernelStatus describes the status of a kernel

func (*KernelStatus) DeepCopy

func (in *KernelStatus) DeepCopy() *KernelStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KernelStatus.

func (*KernelStatus) DeepCopyInto

func (in *KernelStatus) DeepCopyInto(out *KernelStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type NetworkMode

type NetworkMode string

NetworkMode defines different states a VM can be in

const (
	// NetworkModeCNI specifies the network mode where CNI is used
	NetworkModeCNI NetworkMode = "cni"
	// NetworkModeDockerBridge specifies the default docker bridge network is used
	NetworkModeDockerBridge NetworkMode = "docker-bridge"
)

func (NetworkMode) String

func (nm NetworkMode) String() string

type OCIImageClaim

type OCIImageClaim struct {
	// Type defines how the image should be imported
	Type ImageSourceType `json:"type"`
	// Ref defines the reference to use when talking to the backend.
	// This is most commonly the image name, followed by a tag.
	// Other supported ways are $registry/$user/$image@sha256:$digest
	// This ref is also used as ObjectMeta.Name for kinds Images and Kernels
	Ref meta.OCIImageRef `json:"ref"`
}

OCIImageClaim defines a claim for importing an OCI image

func (*OCIImageClaim) DeepCopy

func (in *OCIImageClaim) DeepCopy() *OCIImageClaim

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OCIImageClaim.

func (*OCIImageClaim) DeepCopyInto

func (in *OCIImageClaim) DeepCopyInto(out *OCIImageClaim)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type OCIImageSource

type OCIImageSource struct {
	// ID defines the source's ID (e.g. the Docker image ID)
	ID string `json:"id"`
	// Size defines the size of the source in bytes
	Size meta.Size `json:"size"`
	// RepoDigests defines the image name as it was when pulled
	// from a repository, and the digest of the image
	// The format is $registry/$user/$image@sha256:$digest
	// This field is unpopulated if the image used as the source
	// has never been pushed to or pulled from a registry
	RepoDigests []string `json:"repoDigests,omitempty"`
}

OCIImageSource specifies how the OCI image was imported. It is the status variant of OCIImageClaim

func (*OCIImageSource) DeepCopy

func (in *OCIImageSource) DeepCopy() *OCIImageSource

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OCIImageSource.

func (*OCIImageSource) DeepCopyInto

func (in *OCIImageSource) DeepCopyInto(out *OCIImageSource)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Pool

type Pool struct {
	meta.TypeMeta `json:",inline"`

	Spec   PoolSpec   `json:"spec"`
	Status PoolStatus `json:"status"`
}

Pool defines device mapper pool database This file is managed by the snapshotter part of Ignite, and the file (existing as a singleton) is present at /var/lib/firecracker/snapshotter/pool.json +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

func (*Pool) DeepCopy

func (in *Pool) DeepCopy() *Pool

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Pool.

func (*Pool) DeepCopyInto

func (in *Pool) DeepCopyInto(out *Pool)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Pool) DeepCopyObject

func (in *Pool) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type PoolDevice

type PoolDevice struct {
	Size   meta.Size `json:"size"`
	Parent meta.DMID `json:"parent"`
	// Type specifies the type of the contents of the device
	Type PoolDeviceType `json:"type"`
	// MetadataPath points to the JSON/YAML file with metadata about this device
	// This is most often of the format /var/lib/firecracker/{type}/{id}/metadata.json
	MetadataPath string `json:"metadataPath"`
}

PoolDevice defines one device in the pool

func (*PoolDevice) DeepCopy

func (in *PoolDevice) DeepCopy() *PoolDevice

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PoolDevice.

func (*PoolDevice) DeepCopyInto

func (in *PoolDevice) DeepCopyInto(out *PoolDevice)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type PoolDeviceType

type PoolDeviceType string
const (
	PoolDeviceTypeImage  PoolDeviceType = "Image"
	PoolDeviceTypeResize PoolDeviceType = "Resize"
	PoolDeviceTypeKernel PoolDeviceType = "Kernel"
	PoolDeviceTypeVM     PoolDeviceType = "VM"
)

type PoolSpec

type PoolSpec struct {
	// MetadataSize specifies the size of the pool's metadata
	MetadataSize meta.Size `json:"metadataSize"`
	// DataSize specifies the size of the pool's data
	DataSize meta.Size `json:"dataSize"`
	// AllocationSize specifies the smallest size that can be allocated at a time
	AllocationSize meta.Size `json:"allocationSize"`
	// MetadataPath points to the file where device mapper stores all metadata information
	// Defaults to constants.SNAPSHOTTER_METADATA_PATH
	MetadataPath string `json:"metadataPath"`
	// DataPath points to the backing physical device or sparse file (to be loop mounted) for the pool
	// Defaults to constants.SNAPSHOTTER_DATA_PATH
	DataPath string `json:"dataPath"`
}

PoolSpec defines the Pool's specification

func (*PoolSpec) DeepCopy

func (in *PoolSpec) DeepCopy() *PoolSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PoolSpec.

func (*PoolSpec) DeepCopyInto

func (in *PoolSpec) DeepCopyInto(out *PoolSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type PoolStatus

type PoolStatus struct {
	// The Devices array needs to contain pointers to accommodate "holes" in the mapping
	// Where devices have been deleted, the pointer is nil
	Devices []*PoolDevice `json:"devices"`
}

PoolStatus defines the Pool's current status

func (*PoolStatus) DeepCopy

func (in *PoolStatus) DeepCopy() *PoolStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PoolStatus.

func (*PoolStatus) DeepCopyInto

func (in *PoolStatus) DeepCopyInto(out *PoolStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type SSH

type SSH struct {
	Generate  bool   `json:"-"`
	PublicKey string `json:"-"`
}

SSH specifies different ways to connect via SSH to the VM SSH uses a custom marshaller/unmarshaller. If generate is true, it marshals to true (a JSON bool). If PublicKey is set, it marshals to that string.

func (*SSH) DeepCopy

func (in *SSH) DeepCopy() *SSH

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SSH.

func (*SSH) DeepCopyInto

func (in *SSH) DeepCopyInto(out *SSH)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*SSH) MarshalJSON

func (s *SSH) MarshalJSON() ([]byte, error)

func (*SSH) UnmarshalJSON

func (s *SSH) UnmarshalJSON(b []byte) error

type VM

type VM struct {
	meta.TypeMeta `json:",inline"`
	// meta.ObjectMeta is also embedded into the struct, and defines the human-readable name, and the machine-readable ID
	// Name is available at the .metadata.name JSON path
	// ID is available at the .metadata.uid JSON path (the Go type is k8s.io/apimachinery/pkg/types.UID, which is only a typed string)
	meta.ObjectMeta `json:"metadata"`

	Spec   VMSpec   `json:"spec"`
	Status VMStatus `json:"status"`
}

VM represents a virtual machine run by Firecracker These files are stored in /var/lib/firecracker/vm/{vm-id}/metadata.json +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

func (*VM) DeepCopy

func (in *VM) DeepCopy() *VM

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VM.

func (*VM) DeepCopyInto

func (in *VM) DeepCopyInto(out *VM)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*VM) DeepCopyObject

func (in *VM) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type VMImageSpec

type VMImageSpec struct {
	OCIClaim OCIImageClaim `json:"ociClaim"`
}

func (*VMImageSpec) DeepCopy

func (in *VMImageSpec) DeepCopy() *VMImageSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VMImageSpec.

func (*VMImageSpec) DeepCopyInto

func (in *VMImageSpec) DeepCopyInto(out *VMImageSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type VMKernelSpec

type VMKernelSpec struct {
	OCIClaim OCIImageClaim `json:"ociClaim"`
	CmdLine  string        `json:"cmdLine,omitempty"`
}

func (*VMKernelSpec) DeepCopy

func (in *VMKernelSpec) DeepCopy() *VMKernelSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VMKernelSpec.

func (*VMKernelSpec) DeepCopyInto

func (in *VMKernelSpec) DeepCopyInto(out *VMKernelSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type VMNetworkSpec

type VMNetworkSpec struct {
	Mode  NetworkMode       `json:"mode"`
	Ports meta.PortMappings `json:"ports,omitempty"`
}

func (*VMNetworkSpec) DeepCopy

func (in *VMNetworkSpec) DeepCopy() *VMNetworkSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VMNetworkSpec.

func (*VMNetworkSpec) DeepCopyInto

func (in *VMNetworkSpec) DeepCopyInto(out *VMNetworkSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type VMSpec

type VMSpec struct {
	Image    VMImageSpec   `json:"image"`
	Kernel   VMKernelSpec  `json:"kernel"`
	CPUs     uint64        `json:"cpus"`
	Memory   meta.Size     `json:"memory"`
	DiskSize meta.Size     `json:"diskSize"`
	Network  VMNetworkSpec `json:"network"`

	// This will be done at either "ignite start" or "ignite create" time
	// TODO: We might revisit this later
	CopyFiles []FileMapping `json:"copyFiles,omitempty"`
	// SSH specifies how the SSH setup should be done
	// nil here means "don't do anything special"
	// If SSH.Generate is set, Ignite will generate a new SSH key and copy it in to authorized_keys in the VM
	// Specifying a path in SSH.Generate means "use this public key"
	// If SSH.PublicKey is set, this struct will marshal as a string using that path
	// If SSH.Generate is set, this struct will marshal as a bool => true
	SSH *SSH `json:"ssh,omitempty"`
}

VMSpec describes the configuration of a VM

func (*VMSpec) DeepCopy

func (in *VMSpec) DeepCopy() *VMSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VMSpec.

func (*VMSpec) DeepCopyInto

func (in *VMSpec) DeepCopyInto(out *VMSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type VMState

type VMState string

VMState defines different states a VM can be in

const (
	VMStateCreated VMState = "Created"
	VMStateRunning VMState = "Running"
	VMStateStopped VMState = "Stopped"
)

type VMStatus

type VMStatus struct {
	State       VMState          `json:"state"`
	IPAddresses meta.IPAddresses `json:"ipAddresses,omitempty"`
	Image       OCIImageSource   `json:"image"`
	Kernel      OCIImageSource   `json:"kernel"`
}

VMStatus defines the status of a VM

func (*VMStatus) DeepCopy

func (in *VMStatus) DeepCopy() *VMStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VMStatus.

func (*VMStatus) DeepCopyInto

func (in *VMStatus) DeepCopyInto(out *VMStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

Jump to

Keyboard shortcuts

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