v1alpha2

package
v0.0.11 Latest Latest
Warning

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

Go to latest
Published: Jun 16, 2021 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package v1alpha2 contains core Equinix Metal resources. +kubebuilder:object:generate=true +groupName=server.metal.equinix.com +versionName=v1alpha2

Index

Constants

View Source
const (
	// StatePoweringOn indicates device is powering on
	StatePoweringOn = "powering_on"

	// StatePoweringOff indicates device is powering off
	StatePoweringOff = "powering_off"

	// StateActive indicates device is in active state
	StateActive = "active"

	// StateInactive indicates device is in inactive state
	StateInactive = "inactive"

	// StateProvisioning indicates device is in provisioning state
	StateProvisioning = "provisioning"

	// StateDeprovisioning indicates device is in deprovisioning state
	StateDeprovisioning = "deprovisioning"

	// StateReinstalling indicates device is in reinstalling state
	StateReinstalling = "reinstalling"

	// StateFailed indicates device is in a failed state
	StateFailed = "failed"

	// StateQueued indicates device is in a queued state
	StateQueued = "queued"
)
View Source
const (
	Group   = "server.metal.equinix.com"
	Version = "v1alpha2"
)

Equinix Metal type metadata.

Variables

View Source
var (
	// SchemeGroupVersion is group version used to register these objects
	SchemeGroupVersion = schema.GroupVersion{Group: Group, Version: Version}

	// SchemeBuilder is used to add go types to the GroupVersionKind scheme
	SchemeBuilder = &scheme.Builder{GroupVersion: SchemeGroupVersion}
)
View Source
var (
	DeviceKind             = reflect.TypeOf(Device{}).Name()
	DeviceGroupKind        = schema.GroupKind{Group: Group, Kind: DeviceKind}.String()
	DeviceKindAPIVersion   = DeviceKind + "." + SchemeGroupVersion.String()
	DeviceGroupVersionKind = SchemeGroupVersion.WithKind(DeviceKind)
)

Device type metadata.

Functions

func DeviceID

func DeviceID() reference.ExtractValueFn

DeviceID extracts the ID of a Device.

Types

type DataKeySelector added in v0.0.6

type DataKeySelector struct {
	NamespacedName `json:",inline,omitempty"`
	// +kubebuilder:validation:Enum=Secret;ConfigMap
	Kind     string `json:"kind"`
	Key      string `json:"key,omitempty"`
	Optional bool   `json:"optional,omitempty"`
}

DataKeySelector defines required spec to access a key of a configmap or secret

func (*DataKeySelector) DeepCopy added in v0.0.6

func (in *DataKeySelector) DeepCopy() *DataKeySelector

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

func (*DataKeySelector) DeepCopyInto added in v0.0.6

func (in *DataKeySelector) DeepCopyInto(out *DataKeySelector)

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

type Device

type Device struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   DeviceSpec   `json:"spec"`
	Status DeviceStatus `json:"status,omitempty"`
}

Device is a managed resource that represents an Equinix Metal Device +kubebuilder:printcolumn:name="READY",type="string",JSONPath=".status.conditions[?(@.type=='Ready')].status" +kubebuilder:printcolumn:name="SYNCED",type="string",JSONPath=".status.conditions[?(@.type=='Synced')].status" +kubebuilder:printcolumn:name="STATE",type="string",JSONPath=".status.atProvider.state" +kubebuilder:printcolumn:name="ID",type="string",JSONPath=".status.atProvider.id" +kubebuilder:printcolumn:name="HOSTNAME",type="string",JSONPath=".spec.forProvider.hostname" +kubebuilder:printcolumn:name="METRO",type="string",JSONPath=".status.atProvider.metro" +kubebuilder:printcolumn:name="FACILITY",type="string",JSONPath=".status.atProvider.facility",priority=1 +kubebuilder:printcolumn:name="IPV4",type="string",JSONPath=".status.atProvider.ipv4" +kubebuilder:printcolumn:name="RECLAIM-POLICY",type="string",JSONPath=".spec.reclaimPolicy" +kubebuilder:printcolumn:name="AGE",type="date",JSONPath=".metadata.creationTimestamp" +kubebuilder:subresource:status +kubebuilder:resource:scope=Cluster,categories={crossplane,managed,equinix}

func (*Device) DeepCopy

func (in *Device) DeepCopy() *Device

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

func (*Device) DeepCopyInto

func (in *Device) DeepCopyInto(out *Device)

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

func (*Device) DeepCopyObject

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

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

func (*Device) GetCondition

func (mg *Device) GetCondition(ct xpv1.ConditionType) xpv1.Condition

GetCondition of this Device.

func (*Device) GetDeletionPolicy

func (mg *Device) GetDeletionPolicy() xpv1.DeletionPolicy

GetDeletionPolicy of this Device.

func (*Device) GetProviderConfigReference

func (mg *Device) GetProviderConfigReference() *xpv1.Reference

GetProviderConfigReference of this Device.

func (*Device) GetProviderReference

func (mg *Device) GetProviderReference() *xpv1.Reference

GetProviderReference of this Device. Deprecated: Use GetProviderConfigReference.

func (*Device) GetWriteConnectionSecretToReference

func (mg *Device) GetWriteConnectionSecretToReference() *xpv1.SecretReference

GetWriteConnectionSecretToReference of this Device.

func (*Device) SetConditions

func (mg *Device) SetConditions(c ...xpv1.Condition)

SetConditions of this Device.

func (*Device) SetDeletionPolicy

func (mg *Device) SetDeletionPolicy(r xpv1.DeletionPolicy)

SetDeletionPolicy of this Device.

func (*Device) SetProviderConfigReference

func (mg *Device) SetProviderConfigReference(r *xpv1.Reference)

SetProviderConfigReference of this Device.

func (*Device) SetProviderReference

func (mg *Device) SetProviderReference(r *xpv1.Reference)

SetProviderReference of this Device. Deprecated: Use SetProviderConfigReference.

func (*Device) SetWriteConnectionSecretToReference

func (mg *Device) SetWriteConnectionSecretToReference(r *xpv1.SecretReference)

SetWriteConnectionSecretToReference of this Device.

type DeviceList

type DeviceList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []Device `json:"items"`
}

DeviceList contains a list of Devices

func (*DeviceList) DeepCopy

func (in *DeviceList) DeepCopy() *DeviceList

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

func (*DeviceList) DeepCopyInto

func (in *DeviceList) DeepCopyInto(out *DeviceList)

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

func (*DeviceList) DeepCopyObject

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

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

func (*DeviceList) GetItems

func (l *DeviceList) GetItems() []resource.Managed

GetItems of this DeviceList.

type DeviceObservation

type DeviceObservation struct {
	ID   string `json:"id"`
	Href string `json:"href,omitempty"`

	// Facility is where the device is deployed. This field may differ from
	// spec.forProvider.facility when the "any" value was used.
	Facility            string            `json:"facility"`
	Metro               string            `json:"metro,omitempty"`
	State               string            `json:"state,omitempty"`
	ProvisionPercentage resource.Quantity `json:"provisionPercentage,omitempty"`
	IPv4                string            `json:"ipv4,omitempty"`
	Locked              bool              `json:"locked"`

	// +optional
	CreatedAt *metav1.Time `json:"createdAt,omitempty"`

	// +optional
	UpdatedAt *metav1.Time `json:"updatedAt,omitempty"`
}

DeviceObservation is used to reflect in the Kubernetes API, the observed state of the Device resource from the Equinix Metal API.

func (*DeviceObservation) DeepCopy

func (in *DeviceObservation) DeepCopy() *DeviceObservation

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

func (*DeviceObservation) DeepCopyInto

func (in *DeviceObservation) DeepCopyInto(out *DeviceObservation)

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

type DeviceParameters

type DeviceParameters struct {
	// +immutable
	// +required
	Plan string `json:"plan"`

	// +immutable
	Facility string `json:"facility,omitempty"`

	// +immutable
	Metro string `json:"metro,omitempty"`

	// +immutable
	// +required
	OS string `json:"operatingSystem"`

	// +optional
	Hostname *string `json:"hostname,omitempty"`

	// +optional
	Description *string `json:"description,omitempty"`

	// +optional
	BillingCycle *string `json:"billingCycle,omitempty"`

	// +optional
	UserData *string `json:"userdata,omitempty"`

	// +optional
	UserDataRef *DataKeySelector `json:"userdataRef,omitempty"`

	// +optional
	Tags []string `json:"tags,omitempty"`

	// +optional
	Locked *bool `json:"locked,omitempty"`

	// +optional
	IPXEScriptURL *string `json:"ipxeScriptUrl,omitempty"`

	// +immutable
	// +optional
	PublicIPv4SubnetSize *int `json:"publicIPv4SubnetSize,omitempty"`

	// +optional
	AlwaysPXE *bool `json:"alwaysPXE,omitempty"`

	// +immutable
	// +optional
	HardwareReservationID *string `json:"hardwareReservationID,omitempty"`

	// +optional
	CustomData *string `json:"customData,omitempty"`

	// +immutable
	// +optional
	UserSSHKeys []string `json:"userSSHKeys,omitempty"`

	// +immutable
	// +optional
	ProjectSSHKeys []string `json:"projectSSHKeys,omitempty"`

	// +optional
	// +kubebuilder:validation:Enum="hybrid";"layer2-individual";"layer2-bonded";"layer3"
	NetworkType *string `json:"networkType,omitempty"`

	// Features can be used to require or prefer devices with optional features:
	//
	// features:
	// - tpm: required
	// - tpm: preferred
	// +immutable
	// +optional
	Features map[string]string `json:"features,omitempty"`

	// IPAddresses will be attached to the device. These addresses can be drawn
	// from existing reservations.
	//
	// +immutable
	// +optional
	IPAddresses []IPAddress `json:"ipAddresses,omitempty"`
}

DeviceParameters define the desired state of an Equinix Metal device. https://metal.equinix.com/developers/api/#devices

Reference values are used for optional parameters to determine if LateInitialization should update the parameter after creation.

func (*DeviceParameters) DeepCopy

func (in *DeviceParameters) DeepCopy() *DeviceParameters

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

func (*DeviceParameters) DeepCopyInto

func (in *DeviceParameters) DeepCopyInto(out *DeviceParameters)

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

type DeviceSpec

type DeviceSpec struct {
	xpv1.ResourceSpec `json:",inline"`
	ForProvider       DeviceParameters `json:"forProvider"`
}

DeviceSpec defines the desired state of Device

func (*DeviceSpec) DeepCopy

func (in *DeviceSpec) DeepCopy() *DeviceSpec

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

func (*DeviceSpec) DeepCopyInto

func (in *DeviceSpec) DeepCopyInto(out *DeviceSpec)

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

type DeviceStatus

type DeviceStatus struct {
	xpv1.ResourceStatus `json:",inline"`
	AtProvider          DeviceObservation `json:"atProvider,omitempty"`
}

DeviceStatus defines the observed state of Device

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 IPAddress added in v0.0.5

type IPAddress struct {
	AddressFamily int      `json:"address_family"`
	Public        bool     `json:"public"`
	CIDR          int      `json:"cidr,omitempty"`
	Reservations  []string `json:"ip_reservations,omitempty"`
}

IPAddress is a packngo.IPAddressCreateRequest used for managing IP addresses at Device, at creation and observer time.

func (*IPAddress) DeepCopy added in v0.0.5

func (in *IPAddress) DeepCopy() *IPAddress

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

func (*IPAddress) DeepCopyInto added in v0.0.5

func (in *IPAddress) DeepCopyInto(out *IPAddress)

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

type NamespacedName added in v0.0.6

type NamespacedName struct {
	Namespace string `json:"namespace"`
	Name      string `json:"name"`
}

NamespacedName represents a namespaced object name

func (*NamespacedName) DeepCopy added in v0.0.6

func (in *NamespacedName) DeepCopy() *NamespacedName

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

func (*NamespacedName) DeepCopyInto added in v0.0.6

func (in *NamespacedName) DeepCopyInto(out *NamespacedName)

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