@@ -85,7 +85,7 @@ type SlurmClusterSpec struct {
8585 // SlurmConfig represents the Slurm configuration in slurm.conf. Not all options are supported.
8686 //
8787 // +kubebuilder:validation:Optional
88- // +kubebuilder:default={defMemPerNode: 1228800 , defCpuPerGPU: 16 , completeWait: 5, debugFlags: "Cgroup,CPU_Bind,Gres,JobComp,Priority,Script,SelectType,Steps,TraceJobs", epilog: "", prolog: "", taskPluginParam: "Autobind=Cores", maxJobCount: 10000, minJobAge: 86400}
88+ // +kubebuilder:default={defMemPerNode: 1048576 , defCpuPerGPU: 4 , completeWait: 5, epilog: "", prolog: "", taskPluginParam: "Autobind=Cores", maxJobCount: 10000, minJobAge: 86400, messageTimeout: 60 }
8989 SlurmConfig SlurmConfig `json:"slurmConfig,omitempty"`
9090
9191 // CustomSlurmConfig represents the raw Slurm configuration from slurm.conf.
@@ -105,7 +105,7 @@ type SlurmClusterSpec struct {
105105 // PlugStackConfig represents the Plugin stack configurations in `plugstack.conf`.
106106 //
107107 // +kubebuilder:validation:Optional
108- // +kubebuilder:default={ pyxis: { required: true, containerImageSave: "/var/cache/enroot-container-images/" }, ncclDebug: { required: false, enabled: false, logLevel: "INFO", outputToFile: true, outputToStdOut: false, outputDirectory: "/opt/soperator-outputs/nccl_logs" } }
108+ // +kubebuilder:default={ pyxis: { required: true, containerImageSave: "/var/cache/enroot-container-images/" }, ncclDebug: { required: false, enabled: false, logLevel: "INFO", outputToFile: true, outputToStdOut: false, outputDirectory: "/opt/soperator-outputs/%h/ nccl_logs" } }
109109 PlugStackConfig PlugStackConfig `json:"plugStackConfig,omitempty"`
110110
111111 // SlurmTopologyConfigMapRefName is the name of the slurm topology config.
@@ -141,24 +141,18 @@ type SlurmConfig struct {
141141 // Default real memory size available per allocated node in mebibytes.
142142 //
143143 // +kubebuilder:validation:Optional
144- // +kubebuilder:default=1228800
144+ // +kubebuilder:default=1048576
145145 DefMemPerNode * int32 `json:"defMemPerNode,omitempty"`
146146 // Default count of CPUs allocated per allocated GPU
147147 //
148148 // +kubebuilder:validation:Optional
149- // +kubebuilder:default=16
149+ // +kubebuilder:default=4
150150 DefCpuPerGPU * int32 `json:"defCpuPerGPU,omitempty"`
151151 // The time to wait, in seconds, when any job is in the COMPLETING state before any additional jobs are scheduled.
152152 //
153153 // +kubebuilder:validation:Optional
154154 // +kubebuilder:default=5
155155 CompleteWait * int32 `json:"completeWait,omitempty"`
156- // Defines specific subsystems which should provide more detailed event logging.
157- //
158- // +kubebuilder:validation:Optional
159- // +kubebuilder:default="Priority,Script,SelectType,Steps"
160- // +kubebuilder:validation:Pattern="^((Accrue|Agent|AuditRPCs|Backfill|BackfillMap|BurstBuffer|Cgroup|ConMgr|CPU_Bind|CpuFrequency|Data|DBD_Agent|Dependency|Elasticsearch|Energy|Federation|FrontEnd|Gres|Hetjob|Gang|GLOB_SILENCE|JobAccountGather|JobComp|JobContainer|License|Network|NetworkRaw|NodeFeatures|NO_CONF_HASH|Power|Priority|Profile|Protocol|Reservation|Route|Script|SelectType|Steps|Switch|TLS|TraceJobs|Triggers)(,)?)+$"
161- DebugFlags * string `json:"debugFlags,omitempty"`
162156 // Defines specific file to run the epilog when job ends. Default value is no epilog
163157 //
164158 // +kubebuilder:validation:Optional
@@ -197,7 +191,7 @@ type SlurmConfig struct {
197191 TopologyPlugin string `json:"topologyPlugin,omitempty"`
198192 // TopologyParam is list of comma-separated options identifying network topology options.
199193 //
200- // +kubebuilder:validation:Optional
194+ // +kubebuilder:default=topology/tree
201195 TopologyParam string `json:"topologyParam,omitempty"`
202196}
203197
@@ -221,7 +215,7 @@ type PlugStackConfig struct {
221215 // NcclDebug represents the 'NCCL Debug' SPANK plugin configuration.
222216 //
223217 // +kubebuilder:validation:Optional
224- // +kubebuilder:default={ required: false, enabled: false, logLevel: "INFO", outputToFile: true, outputToStdOut: false, outputDirectory: "/opt/soperator-outputs/nccl_logs" }
218+ // +kubebuilder:default={ required: false, enabled: false, logLevel: "INFO", outputToFile: true, outputToStdOut: false, outputDirectory: "/opt/soperator-outputs/%h/ nccl_logs" }
225219 NcclDebug PluginConfigNcclDebug `json:"ncclDebug,omitempty"`
226220
227221 // PluginConfigCustom represents a configuration of custom SPANK plugins.
@@ -277,7 +271,7 @@ type PluginConfigNcclDebug struct {
277271
278272 // OutputToFile defines whether to additionally redirect `NCCL_DEBUG` outputs to the output file.
279273 // Output filename will have the following format:
280- // <WORKER_NAME>.< JOB_ID>.<STEP_ID>.out
274+ // <JOB_ID>.<STEP_ID>.out
281275 //
282276 // +kubebuilder:validation:Optional
283277 // +kubebuilder:default=true
@@ -298,7 +292,7 @@ type PluginConfigNcclDebug struct {
298292 // If the path does not exist, it will be created by the plugin.
299293 //
300294 // +kubebuilder:validation:Optional
301- // +kubebuilder:default="/opt/soperator-outputs/nccl_logs"
295+ // +kubebuilder:default="/opt/soperator-outputs/%h/ nccl_logs"
302296 OutputDirectory string `json:"outputDirectory,omitempty"`
303297}
304298
@@ -720,10 +714,35 @@ type ExternalDB struct {
720714 //
721715 // +kubebuilder:validation:Optional
722716 User string `json:"user"`
723- // SecretRef defines the reference to the secret with the password key for the external database
717+ // PasswordSecretKeyRef defines the reference to the secret with the password key for the external database.
718+ // Either this or tls.clientCertSecretName must be provided as client credentials.
724719 //
725720 // +kubebuilder:validation:Optional
726721 PasswordSecretKeyRef PasswordSecretKeyRef `json:"passwordSecretKeyRef"`
722+ // TLS provides the configuration required to establish TLS connection with the external MariaDB.
723+ //
724+ // +kubebuilder:validation:Optional
725+ TLS ExternalDBTLSConfig `json:"tls,omitempty"`
726+ // StorageParameters defines the list of additional parameters to set in slurmdbd.conf's StorageParameters.
727+ // Some values here may be overridden by TLS configuration
728+ //
729+ // +kubebuilder:validation:Optional
730+ StorageParameters map [string ]string `json:"storageParameters,omitempty"`
731+ }
732+
733+ type ExternalDBTLSConfig struct {
734+ // ServerCASecretRef defines the reference to a Secret containing the MariaDB server CA certificates.
735+ // The secret should contain a 'ca.crt' key.
736+ // If set, it overrides SSL_CA value in storageParameters
737+ //
738+ // +kubebuilder:validation:Optional
739+ ServerCASecretRef string `json:"serverCASecretRef,omitempty"`
740+ // ClientCertSecretName defines the reference to a Kubernetes TLS Secret (with tls.crt and tls.key files).
741+ // Either this or passwordSecretKeyRef must be provided as client credentials.
742+ // If set, it overrides SSL_CERT and SSL_KEY values in storageParameters
743+ //
744+ // +kubebuilder:validation:Optional
745+ ClientCertSecretRef string `json:"clientCertSecretRef,omitempty"`
727746}
728747
729748type PasswordSecretKeyRef struct {
0 commit comments