v1alpha1

package
v0.5.0-dev Latest Latest
Warning

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

Go to latest
Published: Sep 27, 2021 License: Apache-2.0 Imports: 9 Imported by: 17

Documentation

Overview

Package v1alpha1 contains API Schema definitions for the run v1alpha1 API group +kubebuilder:object:generate=true +groupName=run.tanzu.vmware.com

Index

Constants

View Source
const (
	// VirtualMachineStateNotFound is the string representing a VM that cannot be located.
	VirtualMachineStateNotFound = VirtualMachineState("notfound")

	// VirtualMachineStatePending is the string representing a VM with an in-flight task.
	VirtualMachineStatePending = VirtualMachineState("pending")

	// VirtualMachineStateCreated is the string representing a VM that's been created
	VirtualMachineStateCreated = VirtualMachineState("created")

	// VirtualMachineStatePoweredOn is the string representing a VM that has successfully powered on
	VirtualMachineStatePoweredOn = VirtualMachineState("poweredon")

	// VirtualMachineStateReady is the string representing a powered-on VM with reported IP addresses.
	VirtualMachineStateReady = VirtualMachineState("ready")

	// VirtualMachineStateDeleting is the string representing a machine that still exists, but has a deleteTimestamp
	// Note that once a VirtualMachine is finally deleted, its state will be VirtualMachineStateNotFound
	VirtualMachineStateDeleting = VirtualMachineState("deleting")

	// VirtualMachineStateError is reported if an error occurs determining the status
	VirtualMachineStateError = VirtualMachineState("error")
)
View Source
const (
	// TanzuKubernetesClusterAddonsStatusPending means addon not yet applied and
	// no error.
	TanzuKubernetesClusterAddonsStatusPending = TanzuKubernetesClusterAddonStatus("pending")

	// TanzuKubernetesClusterAddonsStatusError means an error happened.
	TanzuKubernetesClusterAddonsStatusError = TanzuKubernetesClusterAddonStatus("error")

	// TanzuKubernetesClusterAddonsStatusApplied means that the addon was
	// successfully applied.
	TanzuKubernetesClusterAddonsStatusApplied = TanzuKubernetesClusterAddonStatus("applied")

	// TanzuKubernetesClusterAddonsStatusUnmanaged means that the addon is not
	// being managed by the addons controller and the status is unknown. This
	// should not be considered as an error nor should it block rolling updates.
	TanzuKubernetesClusterAddonsStatusUnmanaged = TanzuKubernetesClusterAddonStatus("unmanaged")
)
View Source
const (
	// TanzuKubernetesClusterPhaseCreating means that the cluster control plane
	// is under creation, or that cluster can start provisioning, or that the
	// infrastructure has been created and configured but not yet with an
	// initialized control plane.
	TanzuKubernetesClusterPhaseCreating = TanzuKubernetesClusterPhase("creating")

	// TanzuKubernetesClusterPhaseRunning means that the infrastructure has been
	// created and configured, and that the control plane has been fully
	// initialized.
	TanzuKubernetesClusterPhaseRunning = TanzuKubernetesClusterPhase("running")

	// TanzuKubernetesClusterPhaseDeleting means that the cluster is being
	// deleted.
	TanzuKubernetesClusterPhaseDeleting = TanzuKubernetesClusterPhase("deleting")

	// TanzuKubernetesClusterPhaseFailed means that cluster control plane
	// creation failed. CAPI's documentation states that the system likely
	// requires user intervention.
	TanzuKubernetesClusterPhaseFailed = TanzuKubernetesClusterPhase("failed")

	// TanzuKubernetesClusterPhaseUpdating indicates that the cluster is in the
	// process of rolling out an update
	TanzuKubernetesClusterPhaseUpdating = TanzuKubernetesClusterPhase("updating")

	// TanzuKubernetesClusterPhaseUpdateFailed indicates that the cluster's
	// rolling update failed and likely requires user intervention.
	TanzuKubernetesClusterPhaseUpdateFailed = TanzuKubernetesClusterPhase("updateFailed")

	// TanzuKubernetesClusterPhaseEmpty is useful for the initial reconcile,
	// before we even state the phase as creating.
	TanzuKubernetesClusterPhaseEmpty = TanzuKubernetesClusterPhase("")
)
View Source
const (
	// NodeStatusPending means that the node has not yet joined.
	NodeStatusPending = NodeStatus("pending")

	// NodeStatusUnknown means that the node is joined, but returning Ready Condition Unknown.
	NodeStatusUnknown = NodeStatus("unknown")

	// NodeStatusReady means that the node is joined, but returning Ready Condition True.
	NodeStatusReady = NodeStatus("ready")

	// NodeStatusNotReady means that the node is joined, but returning Ready Condition False.
	NodeStatusNotReady = NodeStatus("notready")
)
View Source
const (
	// ConditionCompatible indicates the condition is compatible.
	ConditionCompatible = "Compatible"

	// ConditionUpdatesAvailable indicates the condition is an updates is available.
	ConditionUpdatesAvailable = "UpdatesAvailable"

	// ConditionUpgradeAvailable (deprecated) indicates the condition is an updates is available.
	ConditionUpgradeAvailable = "UpgradeAvailable"
)

Variables

View Source
var (
	// GroupVersion is group version used to register these objects
	GroupVersion = schema.GroupVersion{Group: "run.tanzu.vmware.com", Version: "v1alpha1"}

	// SchemeBuilder is used to add go types to the GroupVersionKind scheme
	SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion}

	// AddToScheme adds the types in this group-version to the given scheme.
	AddToScheme = SchemeBuilder.AddToScheme
)

Functions

This section is empty.

Types

type APIEndpoint

type APIEndpoint struct {
	// The hostname on which the API server is serving.
	Host string `json:"host"`

	// The port on which the API server is serving.
	Port int `json:"port"`
}

APIEndpoint represents a reachable Kubernetes API endpoint.

func (*APIEndpoint) DeepCopy

func (in *APIEndpoint) DeepCopy() *APIEndpoint

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

func (*APIEndpoint) DeepCopyInto

func (in *APIEndpoint) DeepCopyInto(out *APIEndpoint)

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

type AddonStatus

type AddonStatus struct {
	// Name of the add-on used.
	Name string `json:"name"`

	// LastErrorMessage contains any error that may have happened before and up to the current status. If it is set, it
	// means that status equaled error at some point in the past.
	// +optional
	LastErrorMessage string `json:"lastErrorMessage,omitempty"`

	// Status is the current state: pending, applied or error.
	Status TanzuKubernetesClusterAddonStatus `json:"status"`

	// Version of the distribution applied
	Version string `json:"version,omitempty"`
}

AddonStatus represents the status of an addon. Used for PSP, CNI, CSI, CloudProvider, DNS and Proxy. See AddonsStatuses.

func NewAddonStatus

func NewAddonStatus() *AddonStatus

NewAddonStatus returns an AddonStatus object set to pending.

func (*AddonStatus) DeepCopy

func (in *AddonStatus) DeepCopy() *AddonStatus

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

func (*AddonStatus) DeepCopyInto

func (in *AddonStatus) DeepCopyInto(out *AddonStatus)

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

func (*AddonStatus) IsApplied

func (as *AddonStatus) IsApplied() bool

IsApplied returns true if the Status is applied

func (*AddonStatus) IsAppliedOrUnmanaged

func (as *AddonStatus) IsAppliedOrUnmanaged() bool

IsAppliedOrUnmanaged returns true if the status is applied or unmanaged

func (*AddonStatus) IsUnmanaged

func (as *AddonStatus) IsUnmanaged() bool

IsUnmanaged returns true if the status is unmanaged

func (*AddonStatus) SetApplied

func (as *AddonStatus) SetApplied(addonName, version string)

SetApplied sets the status to applied, records the addon name and version, and clears the last error message

func (*AddonStatus) SetError

func (as *AddonStatus) SetError(err error)

SetError assigns both the Status to error and the LastErrorMessage according to err.

func (*AddonStatus) SetUnmanaged

func (as *AddonStatus) SetUnmanaged()

SetUnmanaged assigns the status to unmanaged

type AddonsStatuses

type AddonsStatuses struct {
	// DNS holds the DNS creation status for the Tanzu Kubernetes cluster.
	// +optional
	DNS *AddonStatus `json:"dns,omitempty"`

	// Proxy holds the Proxy creation status for the Tanzu Kubernetes cluster.
	// +optional
	Proxy *AddonStatus `json:"proxy,omitempty"`

	// PSP holds the default Pod Security Policy creation status for the Tanzu Kubernetes cluster.
	// +optional
	PSP *AddonStatus `json:"psp,omitempty"`

	// CNI holds the Container Networking Interface status for the Tanzu Kubernetes cluster.
	// +optional
	CNI *AddonStatus `json:"cni,omitempty"`

	// CSI holds the Container Storage Interface status for the Tanzu Kubernetes cluster.
	// +optional
	CSI *AddonStatus `json:"csi,omitempty"`

	// Cloudprovider holds the Cloud Provider Interface status for the Tanzu Kubernetes cluster.
	// +optional
	CloudProvider *AddonStatus `json:"cloudprovider,omitempty"`

	// AuthService holds the Auth service status for the Tanzu Kubernetes cluster.
	// +optional
	AuthService *AddonStatus `json:"authsvc,omitempty"`
}

AddonsStatuses groups the statuses of a Tanzu Kubernetes cluster's add-ons. Currently we track application status.

func (*AddonsStatuses) AreAppliedOrUnmanaged

func (addonsStatuses *AddonsStatuses) AreAppliedOrUnmanaged() bool

AreAppliedOrUnmanaged iterates over all of the fields of the AddonsStatuses struct and ensures that they are not nil and are either applied or unmanaged NOTE: At the moment, AddonsStatuses must _only_ contain objects of the type AddonStatus, else this call will panic.

func (*AddonsStatuses) DeepCopy

func (in *AddonsStatuses) DeepCopy() *AddonsStatuses

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

func (*AddonsStatuses) DeepCopyInto

func (in *AddonsStatuses) DeepCopyInto(out *AddonsStatuses)

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

type CNIConfiguration

type CNIConfiguration struct {
	// Name is the name of the CNI plugin to use.
	//
	// Supported values: "calico", "antrea".
	Name string `json:"name"`
}

CNIConfiguration indicates which CNI should be used.

func (*CNIConfiguration) DeepCopy

func (in *CNIConfiguration) DeepCopy() *CNIConfiguration

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

func (*CNIConfiguration) DeepCopyInto

func (in *CNIConfiguration) DeepCopyInto(out *CNIConfiguration)

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

type Capability

type Capability struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`
	// Spec is the capability spec that has cluster queries.
	Spec CapabilitySpec `json:"spec,omitempty"`
	// Status is the capability status that has results of cluster queries.
	Status CapabilityStatus `json:"status,omitempty"`
}

Capability is the Schema for the capabilities API

func (*Capability) DeepCopy

func (in *Capability) DeepCopy() *Capability

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

func (*Capability) DeepCopyInto

func (in *Capability) DeepCopyInto(out *Capability)

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

func (*Capability) DeepCopyObject

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

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

type CapabilityList

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

CapabilityList contains a list of Capability

func (*CapabilityList) DeepCopy

func (in *CapabilityList) DeepCopy() *CapabilityList

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

func (*CapabilityList) DeepCopyInto

func (in *CapabilityList) DeepCopyInto(out *CapabilityList)

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

func (*CapabilityList) DeepCopyObject

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

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

type CapabilitySpec

type CapabilitySpec struct {
	// Queries specifies set of queries that are evaluated.
	// +listType=map
	// +listMapKey=name
	Queries []Query `json:"queries"`
}

CapabilitySpec defines the desired state of Capability.

func (*CapabilitySpec) DeepCopy

func (in *CapabilitySpec) DeepCopy() *CapabilitySpec

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

func (*CapabilitySpec) DeepCopyInto

func (in *CapabilitySpec) DeepCopyInto(out *CapabilitySpec)

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

type CapabilityStatus

type CapabilityStatus struct {
	// Results represents the results of all the queries specified in the spec.
	// +listType=map
	// +listMapKey=name
	Results []Result `json:"results"`
}

CapabilityStatus defines the observed state of Capability

func (*CapabilityStatus) DeepCopy

func (in *CapabilityStatus) DeepCopy() *CapabilityStatus

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

func (*CapabilityStatus) DeepCopyInto

func (in *CapabilityStatus) DeepCopyInto(out *CapabilityStatus)

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

type ClusterAPIStatus

type ClusterAPIStatus struct {
	// APIEndpoints represents the endpoints to communicate with the control plane.
	// +optional
	APIEndpoints []APIEndpoint `json:"apiEndpoints,omitempty"`

	// ErrorReason indicates that there is a problem reconciling the
	// state, and will be set to a token value suitable for
	// programmatic interpretation.
	// +optional
	ErrorReason *ClusterAPIStatusError `json:"errorReason,omitempty"`

	// ErrorMessage indicates that there is a problem reconciling the
	// state, and will be set to a descriptive error message.
	// +optional
	ErrorMessage *string `json:"errorMessage,omitempty"`

	// Phase represents the current phase of cluster actuation.
	// E.g. Pending, Running, Terminating, Failed etc.
	// +optional
	Phase string `json:"phase,omitempty"`
}

ClusterAPIStatus defines the observed state of the underlying CAPI cluster.

func (*ClusterAPIStatus) DeepCopy

func (in *ClusterAPIStatus) DeepCopy() *ClusterAPIStatus

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

func (*ClusterAPIStatus) DeepCopyInto

func (in *ClusterAPIStatus) DeepCopyInto(out *ClusterAPIStatus)

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

type ClusterAPIStatusError

type ClusterAPIStatusError string

ClusterAPIStatusError represents cluster api status error

type ContainerImage

type ContainerImage struct {
	// Repository is the container image repository used by this image. It MUST be a DNS-compatible name.
	// +optional
	Repository string `json:"repository,omitempty"`

	// Name is the container image name without the repository prefix.
	// It MUST be a valid URI path, MAY contain zero or more '/', and SHOULD NOT start or end with '/'.
	Name string `json:"name"`

	// Tag is the container image version tag. It is the suffix coming after ':' in a fully qualified image name.
	// +optional
	Tag string `json:"tag,omitempty"`
}

ContainerImage is a struct representing a single fully qualified container image name, constructed as `{Repository}/{Name}:{Tag}`.

func (*ContainerImage) DeepCopy

func (in *ContainerImage) DeepCopy() *ContainerImage

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

func (*ContainerImage) DeepCopyInto

func (in *ContainerImage) DeepCopyInto(out *ContainerImage)

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

func (ContainerImage) String

func (ci ContainerImage) String() string

type Distribution

type Distribution struct {
	// Version specifies the fully-qualified desired Kubernetes distribution version of the Tanzu Kubernetes cluster. If the
	// cluster exists and is not of the specified version, it will be upgraded.
	//
	// Version is a semantic version string. The version may not be decreased. The major version may not be changed. If
	// the minor version is changed, it may only be incremented; skipping minor versions is not supported.
	//
	// The current observed version of the cluster is held by `status.version`.
	// +optional
	Version string `json:"fullVersion"`

	// VersionHint provides the version webhook with guidance about the desired Kubernetes distribution version of the
	// Tanzu Kubernetes cluster. If a hint is provided without a full version, the most recent distribution matching the hint
	// will be selected.
	//
	// The version selected based on the hint will be stored in the spec as the full version. This ensures that the same
	// version is used if the cluster is scaled out in the future.
	//
	// VersionHint is a semantic prefix of a full version number. (E.g., v1.15.1 matches any distribution of v1.15.1,
	// including v1.15.1+vmware.1-tkg.1 or v1.15.1+vmware.2-tkg.1, but not v1.15.10+vmware.1-tkg.1.)
	//
	// A hint that does not match the full version is invalid and will be rejected.
	//
	// To upgrade a cluster to the most recent version that still matches the hint, leave the hint alone and remove the
	// fullVersion from the spec. This will cause the hint to be re-resolved.
	// +optional
	VersionHint string `json:"version"`
}

Distribution specifies the version of software which should be installed on the control plane and worker nodes. This version information encompasses Kubernetes and its dependencies, the base OS of the node, and add-ons.

func (*Distribution) DeepCopy

func (in *Distribution) DeepCopy() *Distribution

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

func (*Distribution) DeepCopyInto

func (in *Distribution) DeepCopyInto(out *Distribution)

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

type Error

type Error struct {
	// Message is the textual description of the error.
	Message string `json:"message"`
}

Error holds information about an error condition.

func (*Error) DeepCopy

func (in *Error) DeepCopy() *Error

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

func (*Error) DeepCopyInto

func (in *Error) DeepCopyInto(out *Error)

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

type Network

type Network struct {
	// Services specify network settings for services.
	//
	// Defaults to 10.96.0.0/12.
	// +optional
	Services *NetworkRanges `json:"services,omitempty"`

	// Pods specify network settings for pods.
	//
	// Defaults to 192.168.0.0/16.
	// +optional
	Pods *NetworkRanges `json:"pods,omitempty"`

	// ServiceDomain specifies service domain for Tanzu Kubernetes cluster.
	//
	// Defaults to a cluster.local.
	// +optional
	ServiceDomain string `json:"serviceDomain,omitempty"`

	// CNI is the Container Networking Interface plugin for the Tanzu Kubernetes cluster.
	//
	// Defaults to Calico.
	// +optional
	CNI *CNIConfiguration `json:"cni,omitempty"`
}

Network specifies network-related settings for a cluster.

func (*Network) DeepCopy

func (in *Network) DeepCopy() *Network

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

func (*Network) DeepCopyInto

func (in *Network) DeepCopyInto(out *Network)

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

type NetworkRanges

type NetworkRanges struct {
	// CIDRBlocks specifies one or more ranges of IP addresses.
	//
	// Note: supplying multiple ranges many not be supported by all CNI plugins.
	// +optional
	CIDRBlocks []string `json:"cidrBlocks,omitempty"`
}

NetworkRanges describes a collection of IP addresses as a list of ranges.

func (*NetworkRanges) DeepCopy

func (in *NetworkRanges) DeepCopy() *NetworkRanges

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

func (*NetworkRanges) DeepCopyInto

func (in *NetworkRanges) DeepCopyInto(out *NetworkRanges)

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

type NodeStatus

type NodeStatus string

NodeStatus is used to type the constants describing possible node states.

type Query

type Query struct {
	// Name is the unique name of the query.
	// +kubebuilder:validation:Required
	// +kubebuilder:validation:MinLength:=1
	Name string `json:"name"`
	// GroupVersionResources evaluates a slice of GVR queries.
	// +listType=map
	// +listMapKey=name
	// +optional
	GroupVersionResources []QueryGVR `json:"groupVersionResources,omitempty"`
	// Objects evaluates a slice of Object queries.
	// +listType=map
	// +listMapKey=name
	// +optional
	Objects []QueryObject `json:"objects,omitempty"`
	// PartialSchemas evaluates a slice of PartialSchema queries.
	// +listType=map
	// +listMapKey=name
	// +optional
	PartialSchemas []QueryPartialSchema `json:"partialSchemas,omitempty"`
}

Query is a logical grouping of GVR, Object and PartialSchema queries.

func (*Query) DeepCopy

func (in *Query) DeepCopy() *Query

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

func (*Query) DeepCopyInto

func (in *Query) DeepCopyInto(out *Query)

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

type QueryGVR

type QueryGVR struct {
	// Name is the unique name of the query.
	// +kubebuilder:validation:Required
	// +kubebuilder:validation:MinLength:=1
	Name string `json:"name"`
	// Group is the API group to check for in the cluster.
	// +kubebuilder:validation:Required
	// +kubebuilder:validation:MinLength:=1
	Group string `json:"group"`
	// Versions is the slice of versions to check for in the specified API group.
	// +optional
	Versions []string `json:"versions,omitempty"`
	// Resource is the API resource to check for given an API group and a slice of versions.
	// Specifying a Resource requires at least one version to be specified in Versions.
	// +optional
	Resource string `json:"resource,omitempty"`
}

QueryGVR queries for an API group with the optional ability to check for API versions and resource.

func (*QueryGVR) DeepCopy

func (in *QueryGVR) DeepCopy() *QueryGVR

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

func (*QueryGVR) DeepCopyInto

func (in *QueryGVR) DeepCopyInto(out *QueryGVR)

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

type QueryObject

type QueryObject struct {
	// Name is the unique name of the query.
	// +kubebuilder:validation:Required
	// +kubebuilder:validation:MinLength:=1
	Name string `json:"name"`
	// ObjectReference is the ObjectReference to check for in the cluster.
	// +kubebuilder:validation:Required
	ObjectReference corev1.ObjectReference `json:"objectReference"`
	// WithAnnotations are the annotations whose presence is checked in the object.
	// The query succeeds only if all the annotations specified exists.
	// +optional
	WithAnnotations map[string]string `json:"withAnnotations,omitempty"`
	// WithAnnotations are the annotations whose absence is checked in the object.
	// The query succeeds only if all the annotations specified do not exist.
	// +optional
	WithoutAnnotations map[string]string `json:"withoutAnnotations,omitempty"`
}

QueryObject represents any runtime.Object that could exist in a cluster with the ability to check for annotations.

func (*QueryObject) DeepCopy

func (in *QueryObject) DeepCopy() *QueryObject

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

func (*QueryObject) DeepCopyInto

func (in *QueryObject) DeepCopyInto(out *QueryObject)

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

type QueryPartialSchema

type QueryPartialSchema struct {
	// Name is the unique name of the query.
	// +kubebuilder:validation:Required
	// +kubebuilder:validation:MinLength:=1
	Name string `json:"name"`
	// PartialSchema is the partial OpenAPI schema that will be matched in a cluster.
	// +kubebuilder:validation:Required
	// +kubebuilder:validation:MinLength:=1
	PartialSchema string `json:"partialSchema"`
}

QueryPartialSchema queries for any OpenAPI schema that may exist on a cluster.

func (*QueryPartialSchema) DeepCopy

func (in *QueryPartialSchema) DeepCopy() *QueryPartialSchema

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

func (*QueryPartialSchema) DeepCopyInto

func (in *QueryPartialSchema) DeepCopyInto(out *QueryPartialSchema)

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

type QueryResult

type QueryResult struct {
	// Name is the name of the query in spec whose result this struct represents.
	// +kubebuilder:validation:Required
	// +kubebuilder:validation:MinLength:=1
	Name string `json:"name"`
	// Found is a boolean which indicates if the query condition succeeded.
	// +optional
	Found bool `json:"found"`
	// Error indicates if an error occurred while processing the query.
	// +optional
	Error bool `json:"error,omitempty"`
	// ErrorDetail represents the error detail, if an error occurred.
	// +optional
	ErrorDetail string `json:"errorDetail,omitempty"`
	// NotFoundReason provides the reason if the query condition fails.
	// This is non-empty when Found is false.
	// +optional
	NotFoundReason string `json:"notFoundReason,omitempty"`
}

QueryResult represents the result of a single query.

func (*QueryResult) DeepCopy

func (in *QueryResult) DeepCopy() *QueryResult

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

func (*QueryResult) DeepCopyInto

func (in *QueryResult) DeepCopyInto(out *QueryResult)

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

type Result

type Result struct {
	// Name is the unique name of the query.
	// +kubebuilder:validation:Required
	// +kubebuilder:validation:MinLength:=1
	Name string `json:"name"`
	// GroupVersionResources represents results of GVR queries in spec.
	// +listType=map
	// +listMapKey=name
	// +optional
	GroupVersionResources []QueryResult `json:"groupVersionResources,omitempty"`
	// Objects represents results of Object queries in spec.
	// +listType=map
	// +listMapKey=name
	// +optional
	Objects []QueryResult `json:"objects,omitempty"`
	// PartialSchemas represents results of PartialSchema queries in spec.
	// +listType=map
	// +listMapKey=name
	// +optional
	PartialSchemas []QueryResult `json:"partialSchemas,omitempty"`
}

Result represents the results of queries in Query.

func (*Result) DeepCopy

func (in *Result) DeepCopy() *Result

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

func (*Result) DeepCopyInto

func (in *Result) DeepCopyInto(out *Result)

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

type Settings

type Settings struct {
	// Network specifies network-related settings for the cluster.
	// +optional
	Network *Network `json:"network,omitempty"`

	// Storage specifies storage-related settings for the cluster.
	//
	// The storage used for node's disks is controlled by TopologySettings.
	// +optional
	Storage *Storage `json:"storage,omitempty"`
}

Settings specifies configuration information for a cluster.

func (*Settings) DeepCopy

func (in *Settings) DeepCopy() *Settings

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

func (*Settings) DeepCopyInto

func (in *Settings) DeepCopyInto(out *Settings)

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

type Storage

type Storage struct {
	// Classes is a list of storage classes from the supervisor namespace to expose within a cluster.
	//
	// If omitted, all storage classes from the supervisor namespace will be exposed within the cluster.
	// +optional
	Classes []string `json:"classes,omitempty"`
	// DefaultClass is the valid storage class name which is treated as the default storage class within a cluster.
	// If omitted, no default storage class is set
	// +optional
	DefaultClass string `json:"defaultClass,omitempty"`
}

Storage configures persistent storage for a cluster.

func (*Storage) DeepCopy

func (in *Storage) DeepCopy() *Storage

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

func (*Storage) DeepCopyInto

func (in *Storage) DeepCopyInto(out *Storage)

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

type TanzuKubernetesCluster

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

	Spec   TanzuKubernetesClusterSpec   `json:"spec,omitempty"`
	Status TanzuKubernetesClusterStatus `json:"status,omitempty"`
}

TanzuKubernetesCluster is the schema for the Tanzu Kubernetes Grid service for vSphere API.

+kubebuilder:object:root=true +kubebuilder:resource:path=tanzukubernetesclusters,scope=Namespaced,shortName=tkc +kubebuilder:storageversion +kubebuilder:subresource:status +kubebuilder:printcolumn:name="Control Plane",type=integer,JSONPath=.spec.topology.controlPlane.count +kubebuilder:printcolumn:name="Worker",type=integer,JSONPath=.spec.topology.workers.count +kubebuilder:printcolumn:name="Distribution",type=string,JSONPath=.spec.distribution.fullVersion +kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp" +kubebuilder:printcolumn:name="Phase",type="string",JSONPath=".status.phase"

func (*TanzuKubernetesCluster) DeepCopy

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

func (*TanzuKubernetesCluster) DeepCopyInto

func (in *TanzuKubernetesCluster) DeepCopyInto(out *TanzuKubernetesCluster)

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

func (*TanzuKubernetesCluster) DeepCopyObject

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

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

type TanzuKubernetesClusterAddonStatus

type TanzuKubernetesClusterAddonStatus string

TanzuKubernetesClusterAddonStatus is used to type the constants describing possible addon states.

type TanzuKubernetesClusterList

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

TanzuKubernetesClusterList contains a list of TanzuKubernetesCluster

+kubebuilder:object:root=true

func (*TanzuKubernetesClusterList) DeepCopy

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

func (*TanzuKubernetesClusterList) DeepCopyInto

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

func (*TanzuKubernetesClusterList) DeepCopyObject

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

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

type TanzuKubernetesClusterPhase

type TanzuKubernetesClusterPhase string

TanzuKubernetesClusterPhase is a type for the Tanzu Kubernetes cluster's phase constants.

type TanzuKubernetesClusterSpec

type TanzuKubernetesClusterSpec struct {
	// Topology specifies the topology for the Tanzu Kubernetes cluster: the number, purpose, and organization of the nodes which
	// form the cluster and the resources allocated for each.
	Topology Topology `json:"topology"`

	// Distribution specifies the distribution for the Tanzu Kubernetes cluster: the software installed on the control plane and
	// worker nodes, including Kubernetes itself.
	Distribution Distribution `json:"distribution"`

	// Settings specifies settings for the Tanzu Kubernetes cluster: the way an instance of a distribution is configured,
	// including information about pod networking and storage.
	// +optional
	Settings *Settings `json:"settings,omitempty"`
}

TanzuKubernetesClusterSpec defines the desired state of TanzuKubernetesCluster: its nodes, the software installed on those nodes and the way that software should be configured.

func (*TanzuKubernetesClusterSpec) DeepCopy

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

func (*TanzuKubernetesClusterSpec) DeepCopyInto

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

type TanzuKubernetesClusterStatus

type TanzuKubernetesClusterStatus struct {
	// ClusterAPIStatus describes the abridged status of the underlying Cluster
	// API Cluster status.
	// +optional
	ClusterAPIStatus *ClusterAPIStatus `json:"clusterApiStatus,omitempty"`

	// VMStatus is the VM status from the vSphere Virtual Machine service machines
	VMStatus map[string]VirtualMachineState `json:"vmStatus,omitempty"`

	// NodeStatus is the NodeReadyCondition result from the K8S control plane perspective
	// +optional
	NodeStatus map[string]NodeStatus `json:"nodeStatus,omitempty"`

	// Deprecated: UpgradeStatus is not updated or honored anywhere.
	// +optional
	Upgrade *UpgradeStatus `json:"upgrade,omitempty"`

	// Version holds the observed version of the Tanzu Kubernetes cluster. While an upgrade is in progress this value will be the
	// version of the cluster when the upgrade began.
	// +optional
	Version string `json:"version,omitempty"`

	// Addons groups the statuses of a Tanzu Kubernetes cluster's add-ons.
	// +optional
	Addons *AddonsStatuses `json:"addons,omitempty"`

	// Phase of this TanzuKubernetesCluster.
	// +optional
	Phase TanzuKubernetesClusterPhase `json:"phase,omitempty"`

	// The number of nodes automatically remediated
	NodeRemediationCount int `json:"nodeRemediationCount,omitempty"`
}

TanzuKubernetesClusterStatus defines the observed state of TanzuKubernetesCluster.

func (*TanzuKubernetesClusterStatus) DeepCopy

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

func (*TanzuKubernetesClusterStatus) DeepCopyInto

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

type TanzuKubernetesRelease

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

	Spec   TanzuKubernetesReleaseSpec   `json:"spec,omitempty"`
	Status TanzuKubernetesReleaseStatus `json:"status,omitempty"`
}

TanzuKubernetesRelease is the schema for the tanzukubernetesreleases API. TanzuKubernetesRelease objects represent Kubernetes releases available via TKG, which can be used to create TanzuKubernetesCluster instances. TKRs are immutable to end-users. They are created and managed by TKG to provide discovery of Kubernetes releases to TKG users.

+kubebuilder:object:root=true +kubebuilder:resource:path=tanzukubernetesreleases,scope=Cluster,shortName=tkr +kubebuilder:storageversion +kubebuilder:subresource:status +kubebuilder:printcolumn:name="Version",type=string,JSONPath=.spec.version +kubebuilder:printcolumn:name="Compatible",type=string,JSONPath=.status.conditions[?(@.type=='Compatible')].status +kubebuilder:printcolumn:name="Created",type="date",JSONPath=.metadata.creationTimestamp

func (*TanzuKubernetesRelease) DeepCopy

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

func (*TanzuKubernetesRelease) DeepCopyInto

func (in *TanzuKubernetesRelease) DeepCopyInto(out *TanzuKubernetesRelease)

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

func (*TanzuKubernetesRelease) DeepCopyObject

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

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

func (*TanzuKubernetesRelease) GetConditions

func (r *TanzuKubernetesRelease) GetConditions() clusterv1.Conditions

GetConditions implements capi conditions Getter interface

func (*TanzuKubernetesRelease) SetConditions

func (r *TanzuKubernetesRelease) SetConditions(conditions clusterv1.Conditions)

SetConditions implements capi conditions Setter interface

type TanzuKubernetesReleaseList

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

TanzuKubernetesReleaseList contains a list of TanzuKubernetesRelease

func (*TanzuKubernetesReleaseList) DeepCopy

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

func (*TanzuKubernetesReleaseList) DeepCopyInto

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

func (*TanzuKubernetesReleaseList) DeepCopyObject

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

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

type TanzuKubernetesReleaseSpec

type TanzuKubernetesReleaseSpec struct {
	// Version is the fully qualified Semantic Versioning conformant version of the TanzuKubernetesRelease.
	// Version MUST be unique across all TanzuKubernetesRelease objects.
	Version string `json:"version"`

	// KubernetesVersion is the fully qualified Semantic Versioning conformant version of Kubernetes shipped by this TKR.
	// The same KubernetesVersion MAY be shipped by different TKRs.
	// +optional
	KubernetesVersion string `json:"kubernetesVersion,omitempty"`

	// Repository is the container image repository for Kubernetes core images, such as kube-apiserver, kube-proxy, etc.
	// It MUST be a DNS-compatible name.
	// +optional
	Repository string `json:"repository,omitempty"`

	// Images is the list of (other than Kubernetes core) essential container images shipped by this TKR (e.g. coredns, etcd).
	// +optional
	Images []ContainerImage `json:"images,omitempty"`

	// NodeImageRef refers to an object representing the image used to create TKC nodes (e.g. VirtualMachineImage).
	// +optional
	NodeImageRef *corev1.ObjectReference `json:"nodeImageRef,omitempty"`
}

TanzuKubernetesReleaseSpec defines the desired state of TanzuKubernetesRelease

func (*TanzuKubernetesReleaseSpec) DeepCopy

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

func (*TanzuKubernetesReleaseSpec) DeepCopyInto

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

type TanzuKubernetesReleaseStatus

type TanzuKubernetesReleaseStatus struct {
	Conditions []clusterv1.Condition `json:"conditions,omitempty"`
}

TanzuKubernetesReleaseStatus defines the observed state of TanzuKubernetesRelease

func (*TanzuKubernetesReleaseStatus) DeepCopy

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

func (*TanzuKubernetesReleaseStatus) DeepCopyInto

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

type Topology

type Topology struct {
	// ControlPlane specifies the topology of the cluster's control plane, including the number of control plane nodes
	// and resources allocated for each. The control plane must have an odd number of nodes.
	ControlPlane TopologySettings `json:"controlPlane"`

	// Workers specifies the topology of cluster's worker nodes, including the number of worker nodes and resources
	// allocated for each.
	Workers TopologySettings `json:"workers"`
}

Topology describes the number, purpose, and organization of nodes and the resources allocated for each. Nodes are grouped into pools based on their intended purpose. Each pool is homogeneous, having the same resource allocation and using the same storage.

func (*Topology) DeepCopy

func (in *Topology) DeepCopy() *Topology

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

func (*Topology) DeepCopyInto

func (in *Topology) DeepCopyInto(out *Topology)

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

type TopologySettings

type TopologySettings struct {
	// Count is the number of nodes.
	Count int32 `json:"count"`

	// Class is the name of the VirtualMachineClass, which describes the virtual hardware settings, to be used each node
	// in the pool. This controls the hardware available to the node (CPU and memory) as well as the requests and limits
	// on those resources. Run `kubectl describe virtualmachineclasses` to see which VM classes are available to use.
	Class string `json:"class"`

	// StorageClass is the storage class to be used for storage of the disks which store the root filesystems of the
	// nodes. Run `kubectl describe ns` on your namespace to see which storage classes are available to use.
	StorageClass string `json:"storageClass"`
}

TopologySettings describes a homogeneous pool of nodes: the number of nodes in the pool and the properties of each of those nodes, including resource allocation and storage.

func (*TopologySettings) DeepCopy

func (in *TopologySettings) DeepCopy() *TopologySettings

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

func (*TopologySettings) DeepCopyInto

func (in *TopologySettings) DeepCopyInto(out *TopologySettings)

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

type UpgradeStatus

type UpgradeStatus struct {
	// ToVersion is the target version of the upgrade.
	ToVersion string `json:"toVersion"`

	// Phase is initially empty. Then it has the value of the latest/current phase of the upgrade.
	// In case of successful upgrade, the value is "Success".
	Phase upgrade.Phase `json:"phase"`

	// UpgradeID is an opaque identifier unique to the latest/current upgrade phase.
	// +optional
	UpgradeID string `json:"upgradeId,omitempty"`

	// Finished is false initially and until the upgrade has finished, successfully or not.
	Finished bool `json:"done"`

	// Errors is the list of errors happened during an upgrade. If the upgrade has finished and was not successful, this
	// list should not be empty.
	// +optional
	Errors []Error `json:"errors,omitempty"`
}

UpgradeStatus represents the status of a cluster upgrade.

func (*UpgradeStatus) DeepCopy

func (in *UpgradeStatus) DeepCopy() *UpgradeStatus

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

func (*UpgradeStatus) DeepCopyInto

func (in *UpgradeStatus) DeepCopyInto(out *UpgradeStatus)

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

type VirtualMachineState

type VirtualMachineState string

VirtualMachineState describes the state of a VM.

Directories

Path Synopsis
Package upgrade contains upgrade related api structs
Package upgrade contains upgrade related api structs

Jump to

Keyboard shortcuts

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