Documentation
¶
Overview ¶
Package v1alpha1 contains API Schema definitions for the distributed-compute v1alpha1 API group +kubebuilder:object:generate=true +groupName=distributed-compute.dominodatalab.com
Index ¶
- Variables
- type Autoscaling
- type OCIImageDefinition
- type RayCluster
- func (in *RayCluster) DeepCopy() *RayCluster
- func (in *RayCluster) DeepCopyInto(out *RayCluster)
- func (in *RayCluster) DeepCopyObject() runtime.Object
- func (r *RayCluster) Default()
- func (r *RayCluster) SetupWebhookWithManager(mgr ctrl.Manager) error
- func (r *RayCluster) ValidateCreate() error
- func (r *RayCluster) ValidateDelete() error
- func (r *RayCluster) ValidateUpdate(old runtime.Object) error
- type RayClusterHead
- type RayClusterList
- type RayClusterNetworkPolicy
- type RayClusterNode
- type RayClusterSpec
- type RayClusterStatus
- type RayClusterWorker
Constants ¶
This section is empty.
Variables ¶
var ( // GroupVersion is group version used to register these objects GroupVersion = schema.GroupVersion{Group: "distributed-compute.dominodatalab.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 Autoscaling ¶
type Autoscaling struct {
// MinReplicas is the lower limit for the number of replicas to which the autoscaler can scale down.
// This value must be greater than zero and less than the MaxReplicas.
MinReplicas *int32 `json:"minReplicas,omitempty"`
// MaxReplicas is the upper limit for the number of replicas to which the autoscaler can scale up.
// This value cannot be less than the replica count for your workload.
MaxReplicas int32 `json:"maxReplicas"`
// AverageCPUUtilization is the target value of the average of the resource metric across all relevant pods.
// This is represented as a percentage of the requested value of the resource for the pods.
AverageCPUUtilization *int32 `json:"averageCPUUtilization,omitempty"`
// ScaleDownStabilizationWindowSeconds is the number of seconds for which past recommendations should be considered
// when scaling down. A shorter window will trigger scale down events quicker, but too short a window may cause
// replica flapping when metrics used for scaling keep fluctuating.
ScaleDownStabilizationWindowSeconds *int32 `json:"scaleDownStabilizationWindowSeconds,omitempty"`
}
Autoscaling configuration for scalable workloads.
func (*Autoscaling) DeepCopy ¶
func (in *Autoscaling) DeepCopy() *Autoscaling
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Autoscaling.
func (*Autoscaling) DeepCopyInto ¶
func (in *Autoscaling) DeepCopyInto(out *Autoscaling)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type OCIImageDefinition ¶
type OCIImageDefinition struct {
// Registry where the container image is hosted.
Registry string `json:"registry,omitempty"`
// Repository where the container image is stored.
Repository string `json:"repository,omitempty"`
// Tag points to a specific container image variant.
Tag string `json:"tag,omitempty"`
// PullPolicy used to fetch container image.
PullPolicy corev1.PullPolicy `json:"pullPolicy,omitempty"`
}
OCIImageDefinition describes where and when to fetch a container image.
func (*OCIImageDefinition) DeepCopy ¶
func (in *OCIImageDefinition) DeepCopy() *OCIImageDefinition
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OCIImageDefinition.
func (*OCIImageDefinition) DeepCopyInto ¶
func (in *OCIImageDefinition) DeepCopyInto(out *OCIImageDefinition)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type RayCluster ¶
type RayCluster struct {
metav1.TypeMeta `json:",inline"`
metav1.ObjectMeta `json:"metadata,omitempty"`
Spec RayClusterSpec `json:"spec,omitempty"`
Status RayClusterStatus `json:"status,omitempty"`
}
RayCluster is the Schema for the rayclusters API.
func (*RayCluster) DeepCopy ¶
func (in *RayCluster) DeepCopy() *RayCluster
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RayCluster.
func (*RayCluster) DeepCopyInto ¶
func (in *RayCluster) DeepCopyInto(out *RayCluster)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*RayCluster) DeepCopyObject ¶
func (in *RayCluster) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*RayCluster) Default ¶
func (r *RayCluster) Default()
Default implements webhook.Defaulter so a webhook will be registered for the type
func (*RayCluster) SetupWebhookWithManager ¶
func (r *RayCluster) SetupWebhookWithManager(mgr ctrl.Manager) error
SetupWebhookWithManager creates and registers this webhook with the manager.
func (*RayCluster) ValidateCreate ¶
func (r *RayCluster) ValidateCreate() error
ValidateCreate implements webhook.Validator so a webhook will be registered for the type.
func (*RayCluster) ValidateDelete ¶
func (r *RayCluster) ValidateDelete() error
ValidateDelete implements webhook.Validator so a webhook will be registered for the type. Not used, just here for interface compliance.
func (*RayCluster) ValidateUpdate ¶
func (r *RayCluster) ValidateUpdate(old runtime.Object) error
ValidateUpdate implements webhook.Validator so a webhook will be registered for the type.
type RayClusterHead ¶
type RayClusterHead struct {
RayClusterNode `json:",inline"`
}
RayClusterHead defines head-specific pod settings.
func (*RayClusterHead) DeepCopy ¶
func (in *RayClusterHead) DeepCopy() *RayClusterHead
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RayClusterHead.
func (*RayClusterHead) DeepCopyInto ¶
func (in *RayClusterHead) DeepCopyInto(out *RayClusterHead)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type RayClusterList ¶
type RayClusterList struct {
metav1.TypeMeta `json:",inline"`
metav1.ListMeta `json:"metadata,omitempty"`
Items []RayCluster `json:"items"`
}
RayClusterList contains a list of RayCluster resources.
func (*RayClusterList) DeepCopy ¶
func (in *RayClusterList) DeepCopy() *RayClusterList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RayClusterList.
func (*RayClusterList) DeepCopyInto ¶
func (in *RayClusterList) DeepCopyInto(out *RayClusterList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*RayClusterList) DeepCopyObject ¶
func (in *RayClusterList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type RayClusterNetworkPolicy ¶
type RayClusterNetworkPolicy struct {
ClientServerLabels []map[string]string
DashboardLabels []map[string]string
}
RayClusterNetworkPolicy defines network policy configuration options.
func (*RayClusterNetworkPolicy) DeepCopy ¶
func (in *RayClusterNetworkPolicy) DeepCopy() *RayClusterNetworkPolicy
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RayClusterNetworkPolicy.
func (*RayClusterNetworkPolicy) DeepCopyInto ¶
func (in *RayClusterNetworkPolicy) DeepCopyInto(out *RayClusterNetworkPolicy)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type RayClusterNode ¶
type RayClusterNode struct {
// Labels applied to ray pods in addition to stock labels.
Labels map[string]string `json:"labels,omitempty"`
// Annotations applied to ray pods.
Annotations map[string]string `json:"annotations,omitempty"`
// NodeSelector applied to ray pods.
NodeSelector map[string]string `json:"nodeSelector,omitempty"`
// Affinity applied to ray pods.
Affinity *corev1.Affinity `json:"affinity,omitempty"`
// Tolerations applied to ray pods.
Tolerations []corev1.Toleration `json:"tolerations,omitempty"`
// InitContainers added to ray pods.
InitContainers []corev1.Container `json:"initContainers,omitempty"`
// Volumes added to ray pods.
Volumes []corev1.Volume `json:"volumes,omitempty"`
// VolumeMounts added to ray containers.
VolumeMounts []corev1.VolumeMount `json:"volumeMounts,omitempty"`
// Resources are the requests and limits applied to ray containers.
Resources corev1.ResourceRequirements `json:"resources"`
}
RayClusterNode defines attributes common to all ray node types.
func (*RayClusterNode) DeepCopy ¶
func (in *RayClusterNode) DeepCopy() *RayClusterNode
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RayClusterNode.
func (*RayClusterNode) DeepCopyInto ¶
func (in *RayClusterNode) DeepCopyInto(out *RayClusterNode)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type RayClusterSpec ¶
type RayClusterSpec struct {
// Image used to launch head and worker nodes.
Image *OCIImageDefinition `json:"image,omitempty"`
// ImagePullSecrets are references to secrets with credentials to private registries used to pull images.
ImagePullSecrets []corev1.LocalObjectReference `json:"imagePullSecrets,omitempty"`
// Autoscaling parameters used to scale up/down ray worker nodes.
Autoscaling *Autoscaling `json:"autoscaling,omitempty"`
// Port is the port of the head ray process.
Port int32 `json:"port,omitempty"`
// RedisShardPorts is a list of ports for non-primary Redis shards.
RedisShardPorts []int32 `json:"redisShardPorts,omitempty"`
// ClientServerPort is the port number to which the ray client server will bind.
ClientServerPort int32 `json:"clientServerPort,omitempty"`
// ObjectManagerPort is the raylet port for the object manager.
ObjectManagerPort int32 `json:"objectManagerPort,omitempty"`
// NodeManagerPort is the raylet port for the node manager.
NodeManagerPort int32 `json:"nodeManagerPort,omitempty"`
// ObjectStoreMemoryBytes is initial amount of memory with which to start the object store.
ObjectStoreMemoryBytes *int64 `json:"objectStoreMemoryBytes,omitempty"`
// DashboardPort is the port used by the dashboard server.
DashboardPort int32 `json:"dashboardPort,omitempty"`
// EnableDashboard starts the dashboard web UI.
EnableDashboard *bool `json:"enableDashboard,omitempty"`
// EnableNetworkPolicy will create a network policy that restricts ingress to the cluster.
EnableNetworkPolicy *bool `json:"enableNetworkPolicy,omitempty"`
// NetworkPolicyClientLabels will create a pod selector clause for each set of labels.
// This is used to grant ingress access to one or more groups of external pods and is
// only applicable when EnableNetworkPolicy is true.
NetworkPolicyClientLabels []map[string]string `json:"networkPolicyClientLabels,omitempty"`
// PodSecurityPolicy name can be provided to govern execution of the ray processes within pods.
PodSecurityPolicy string `json:"podSecurityPolicy,omitempty"`
// PodSecurityContext added to every ray pod.
PodSecurityContext *corev1.PodSecurityContext `json:"podSecurityContext,omitempty"`
// ServiceAccountName will disable the creation of a dedicated cluster service account.
// The service account referenced by the provided name will be used instead.
ServiceAccountName string `json:"serviceAccountName,omitempty"`
// EnvVars added to all every ray pod container.
EnvVars []corev1.EnvVar `json:"envVars,omitempty"`
// Head node configuration parameters.
Head RayClusterHead `json:"head,omitempty"`
// Worker node configuration parameters.
Worker RayClusterWorker `json:"worker,omitempty"`
}
RayClusterSpec defines the desired state of a RayCluster resource.
func (*RayClusterSpec) DeepCopy ¶
func (in *RayClusterSpec) DeepCopy() *RayClusterSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RayClusterSpec.
func (*RayClusterSpec) DeepCopyInto ¶
func (in *RayClusterSpec) DeepCopyInto(out *RayClusterSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type RayClusterStatus ¶
type RayClusterStatus struct {
// Nodes that comprise the cluster.
Nodes []string `json:"nodes,omitempty"`
// WorkerReplicas is the scale.status.replicas subresource field.
WorkerReplicas int32 `json:"workerReplicas,omitempty"`
// WorkerSelector is the scale.status.selector subresource field.
WorkerSelector string `json:"workerSelector,omitempty"`
}
RayClusterStatus defines the observed state of a RayCluster resource.
func (*RayClusterStatus) DeepCopy ¶
func (in *RayClusterStatus) DeepCopy() *RayClusterStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RayClusterStatus.
func (*RayClusterStatus) DeepCopyInto ¶
func (in *RayClusterStatus) DeepCopyInto(out *RayClusterStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type RayClusterWorker ¶
type RayClusterWorker struct {
RayClusterNode `json:",inline"`
// Replicas configures the total number of workers in the cluster.
// This field behaves differently when Autoscaling is enabled. If Autoscaling.MinReplicas is unspecified, then the
// minimum number of replicas will be set to this value. Additionally, you can specify an "initial cluster size" by
// setting this field to some value above the minimum number of replicas.
Replicas *int32 `json:"replicas,omitempty"`
}
RayClusterWorker defines worker-specific pod settings.
func (*RayClusterWorker) DeepCopy ¶
func (in *RayClusterWorker) DeepCopy() *RayClusterWorker
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RayClusterWorker.
func (*RayClusterWorker) DeepCopyInto ¶
func (in *RayClusterWorker) DeepCopyInto(out *RayClusterWorker)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.