v1alpha1

package
v0.7.1 Latest Latest
Warning

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

Go to latest
Published: Nov 18, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package v1alpha1 contains API Schema definitions for the jobset v1alpha1 API group +kubebuilder:object:generate=true +groupName=jobset.x-k8s.io

Index

Constants

View Source
const (
	DefaultNamespace                           = "jobset-system"
	DefaultWebhookServiceName                  = "jobset-webhook-service"
	DefaultWebhookSecretName                   = "jobset-webhook-server-cert"
	DefaultWebhookPort                         = 9443
	DefaultHealthProbeBindAddress              = ":8081"
	DefaultMetricsBindAddress                  = ":8080"
	DefaultLeaderElectionID                    = "6d4f6a47.jobset.x-k8s.io"
	DefaultLeaderElectionLeaseDuration         = 15 * time.Second
	DefaultLeaderElectionRenewDeadline         = 10 * time.Second
	DefaultLeaderElectionRetryPeriod           = 2 * time.Second
	DefaultResourceLock                        = "leases"
	DefaultClientConnectionQPS         float32 = 500
	DefaultClientConnectionBurst       int32   = 500
)

Variables

View Source
var (
	// GroupVersion is group version used to register these objects
	GroupVersion = schema.GroupVersion{Group: "config.jobset.x-k8s.io", 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

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_Configuration

func SetDefaults_Configuration(cfg *Configuration)

SetDefaults_Configuration sets default values for ComponentConfig.

func SetObjectDefaults_Configuration

func SetObjectDefaults_Configuration(in *Configuration)

Types

type ClientConnection

type ClientConnection struct {
	// QPS controls the number of queries per second allowed for K8S api server
	// connection.
	QPS *float32 `json:"qps,omitempty"`

	// Burst allows extra queries to accumulate when a client is exceeding its rate.
	Burst *int32 `json:"burst,omitempty"`
}

func (*ClientConnection) DeepCopy

func (in *ClientConnection) DeepCopy() *ClientConnection

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

func (*ClientConnection) DeepCopyInto

func (in *ClientConnection) DeepCopyInto(out *ClientConnection)

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

type Configuration

type Configuration struct {
	metav1.TypeMeta `json:",inline"`

	// Namespace is the namespace in which jobset controller is deployed.
	// It is used as part of DNSName of the webhook Service.
	// If not set, the value is set from the file /var/run/secrets/kubernetes.io/serviceaccount/namespace
	// If the file doesn't exist, default value is kueue-system.
	Namespace *string `json:"namespace,omitempty"`

	// ControllerManager returns the configurations for controllers
	ControllerManager `json:",inline"`

	// InternalCertManagerment is configuration for internalCertManagerment
	InternalCertManagement *InternalCertManagement `json:"internalCertManagement,omitempty"`

	ClientConnection *ClientConnection `json:"clientConnection,omitempty"`
}

Configuration is the Schema for the configurations API

func (*Configuration) DeepCopy

func (in *Configuration) DeepCopy() *Configuration

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

func (*Configuration) DeepCopyInto

func (in *Configuration) DeepCopyInto(out *Configuration)

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

func (*Configuration) DeepCopyObject

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

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

type ControllerHealth

type ControllerHealth struct {
	// HealthProbeBindAddress is the TCP address that the controller should bind to
	// for serving health probes
	// It can be set to "0" or "" to disable serving the health probe.
	// +optional
	HealthProbeBindAddress string `json:"healthProbeBindAddress,omitempty"`

	// ReadinessEndpointName, defaults to "readyz"
	// +optional
	ReadinessEndpointName string `json:"readinessEndpointName,omitempty"`

	// LivenessEndpointName, defaults to "healthz"
	// +optional
	LivenessEndpointName string `json:"livenessEndpointName,omitempty"`
}

ControllerHealth defines the health configs.

func (*ControllerHealth) DeepCopy

func (in *ControllerHealth) DeepCopy() *ControllerHealth

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

func (*ControllerHealth) DeepCopyInto

func (in *ControllerHealth) DeepCopyInto(out *ControllerHealth)

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

type ControllerManager

type ControllerManager struct {
	// Webhook contains the controllers webhook configuration
	// +optional
	Webhook ControllerWebhook `json:"webhook,omitempty"`

	// LeaderElection is the LeaderElection config to be used when configuring
	// the manager.Manager leader election
	// +optional
	LeaderElection *configv1alpha1.LeaderElectionConfiguration `json:"leaderElection,omitempty"`

	// Metrics contains the controller metrics configuration
	// +optional
	Metrics ControllerMetrics `json:"metrics,omitempty"`

	// Health contains the controller health configuration
	// +optional
	Health ControllerHealth `json:"health,omitempty"`
}

func (*ControllerManager) DeepCopy

func (in *ControllerManager) DeepCopy() *ControllerManager

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

func (*ControllerManager) DeepCopyInto

func (in *ControllerManager) DeepCopyInto(out *ControllerManager)

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

type ControllerMetrics

type ControllerMetrics struct {
	// BindAddress is the TCP address that the controller should bind to
	// for serving prometheus metrics.
	// It can be set to "0" to disable the metrics serving.
	// +optional
	BindAddress string `json:"bindAddress,omitempty"`
}

ControllerMetrics defines the metrics configs.

func (*ControllerMetrics) DeepCopy

func (in *ControllerMetrics) DeepCopy() *ControllerMetrics

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

func (*ControllerMetrics) DeepCopyInto

func (in *ControllerMetrics) DeepCopyInto(out *ControllerMetrics)

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

type ControllerWebhook

type ControllerWebhook struct {
	// Port is the port that the webhook server serves at.
	// It is used to set webhook.Server.Port.
	// +optional
	Port *int `json:"port,omitempty"`

	// Host is the hostname that the webhook server binds to.
	// It is used to set webhook.Server.Host.
	// +optional
	Host string `json:"host,omitempty"`

	// CertDir is the directory that contains the server key and certificate.
	// if not set, webhook server would look up the server key and certificate in
	// {TempDir}/k8s-webhook-server/serving-certs. The server key and certificate
	// must be named tls.key and tls.crt, respectively.
	// +optional
	CertDir string `json:"certDir,omitempty"`
}

ControllerWebhook defines the webhook server for the controller.

func (*ControllerWebhook) DeepCopy

func (in *ControllerWebhook) DeepCopy() *ControllerWebhook

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

func (*ControllerWebhook) DeepCopyInto

func (in *ControllerWebhook) DeepCopyInto(out *ControllerWebhook)

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

type InternalCertManagement

type InternalCertManagement struct {
	// Enable controls whether to enable internal cert management or not.
	// Defaults to true. If you want to use a third-party management, e.g. cert-manager,
	// set it to false. See the user guide for more information.
	Enable *bool `json:"enable,omitempty"`

	// WebhookServiceName is the name of the Service used as part of the DNSName.
	// Defaults to jobset-webhook-service.
	WebhookServiceName *string `json:"webhookServiceName,omitempty"`

	// WebhookSecretName is the name of the Secret used to store CA and server certs.
	// Defaults to jobset-webhook-server-cert.
	WebhookSecretName *string `json:"webhookSecretName,omitempty"`
}

func (*InternalCertManagement) DeepCopy

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

func (*InternalCertManagement) DeepCopyInto

func (in *InternalCertManagement) DeepCopyInto(out *InternalCertManagement)

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