Documentation
¶
Overview ¶
Package v1alpha1 is the v1alpha1 version of the cluster API.
Copyright 2023 The Firefly Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Index ¶
Constants ¶
const ( //ClusterReady means cluster is healthy and ready to accept pods. ClusterReadyClusterConditionType = "Ready" //ClusterMemoryPressure means the cluster is under pressure due to insufficient available memory. ClusterMemoryPressureClusterConditionType = "MemoryPressure" //ClusterDiskPressure means the cluster is under pressure due to insufficient available disk. ClusterDiskPressureClusterConditionType = "DiskPressure" //ClusterPIDPressure means the cluster is under pressure due to insufficient available PID. ClusterPIDPressureClusterConditionType = "PIDPressure" ClusterNetworkUnavailableClusterConditionType = "NetworkUnavailable" )
Variables ¶
var ( // SchemeBuilder initializes a scheme builder SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) // AddToScheme is a global function that registers this API group & version to a scheme AddToScheme = SchemeBuilder.AddToScheme )
var SchemeGroupVersion = schema.GroupVersion{Group: cluster.GroupName, Version: "v1alpha1"}
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 Cluster ¶
type Cluster struct { metav1.TypeMeta `json:",inline"` // Standard object's metadata. // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata // +optional metav1.ObjectMeta `json:"metadata,omitempty"` // Spec defines the behavior of a cluster. // https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status // +optional Spec ClusterSpec `json:"spec,omitempty"` // Most recently observed status of the cluster. // Populated by the system. // Read-only. // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status // +optional Status ClusterStatus `json:"status,omitempty"` }
Cluster is a worker cluster in Firefly. Each cluster will have a unique identifier in the cache (i.e. in etcd).
func (*Cluster) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Cluster.
func (*Cluster) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*Cluster) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type ClusterCondition ¶
type ClusterCondition struct { // Type of cluster condition. Type ClusterConditionType `json:"type"` // Status of the condition, one of True, False, Unknown. Status v1.ConditionStatus `json:"status"` // Last time we got an update on a given condition. // +optional LastHeartbeatTime metav1.Time `json:"lastHeartbeatTime,omitempty"` // Last time the condition transit from one status to another. // +optional LastTransitionTime metav1.Time `json:"lastTransitionTime,omitempty"` // (brief) reason for the condition's last transition. // +optional Reason string `json:"reason,omitempty"` // Human readable message indicating details about last transition. // +optional Message string `json:"message,omitempty"` }
ClusterCondition contains condition information for a cluster.
func (*ClusterCondition) DeepCopy ¶
func (in *ClusterCondition) DeepCopy() *ClusterCondition
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterCondition.
func (*ClusterCondition) DeepCopyInto ¶
func (in *ClusterCondition) DeepCopyInto(out *ClusterCondition)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ClusterConditionType ¶
type ClusterConditionType string
type ClusterList ¶
type ClusterList struct { metav1.TypeMeta `json:",inline"` // Standard list metadata. // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds // +optional metav1.ListMeta `json:"metadata,omitempty"` // List of clusters Items []Cluster `json:"items"` }
ClusterList is the whole list of all Clusters which have been registered with Firefly.
func (*ClusterList) DeepCopy ¶
func (in *ClusterList) DeepCopy() *ClusterList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterList.
func (*ClusterList) DeepCopyInto ¶
func (in *ClusterList) DeepCopyInto(out *ClusterList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ClusterList) DeepCopyObject ¶
func (in *ClusterList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type ClusterSpec ¶
type ClusterSpec struct { // Connection is the connection information for the cluster. Connection Connection `json:"connection,omitempty"` }
ClusterSpec describes the attributes that a cluster is created with.
func (*ClusterSpec) DeepCopy ¶
func (in *ClusterSpec) DeepCopy() *ClusterSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterSpec.
func (*ClusterSpec) DeepCopyInto ¶
func (in *ClusterSpec) DeepCopyInto(out *ClusterSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ClusterStatus ¶
type ClusterStatus struct { // Conditions is an array of current observed cluster conditions. // +optional // +patchMergeKey=type // +patchStrategy=merge Conditions []ClusterCondition `json:"conditions,omitempty"` // Set of ids/uuids to uniquely identify the cluster. // +optional ClusterInfo ClusterSystemInfo `json:"clusterInfo,omitempty"` }
ClusterStatus is information about the current status of a cluster.
func (*ClusterStatus) DeepCopy ¶
func (in *ClusterStatus) DeepCopy() *ClusterStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterStatus.
func (*ClusterStatus) DeepCopyInto ¶
func (in *ClusterStatus) DeepCopyInto(out *ClusterStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ClusterSystemInfo ¶
type ClusterSystemInfo struct { // ClusterID reported by the cluster. For unique cluster identification // in Firefly this field is preferred. ClusterID string `json:"clusterID,omitempty"` // Server Version is the Kubernetes version which is reported by the cluster from the API endpoint '/version' (e.g. 1.27). ServerVersion string `json:"serverVersion,omitempty"` }
ClusterSystemInfo is a set of ids/uuids to uniquely identify the cluster.
func (*ClusterSystemInfo) DeepCopy ¶
func (in *ClusterSystemInfo) DeepCopy() *ClusterSystemInfo
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterSystemInfo.
func (*ClusterSystemInfo) DeepCopyInto ¶
func (in *ClusterSystemInfo) DeepCopyInto(out *ClusterSystemInfo)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Connection ¶
type Connection struct { // KubeConfig is the kubeconfig for the cluster. KubeConfig []byte `json:"kubeconfig,omitempty"` }
Connection is the connection information for the cluster.
func (*Connection) DeepCopy ¶
func (in *Connection) DeepCopy() *Connection
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Connection.
func (*Connection) DeepCopyInto ¶
func (in *Connection) DeepCopyInto(out *Connection)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.