Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions soperator/installations/example/terraform.tfvars
Original file line number Diff line number Diff line change
Expand Up @@ -450,6 +450,7 @@ slurm_exporter_enabled = true
# - "testing" - to be used for Soperator E2E tests.
# - "dev" - to be used for Soperator development clusters.
# - "essential" - skip most of checks and run only essential ones. Don't use in production.
# - "cpu" - run only CPU-related checks during bootstrap (`ssh-check` and `mem-perf`).
# ---
active_checks_scope = ""

Expand Down
4 changes: 2 additions & 2 deletions soperator/installations/example/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -1208,8 +1208,8 @@ variable "active_checks_scope" {
description = "Scope of active checks. Defines what active checks should be checked during cluster bootstrap."
default = ""
validation {
condition = contains(["dev", "testing", "prod_quick", "prod_acceptance", "essential"], var.active_checks_scope)
error_message = "active_checks_scope should be one of: dev, testing, prod_quick, prod_acceptance, essential."
condition = contains(["dev", "testing", "prod_quick", "prod_acceptance", "essential", "cpu"], var.active_checks_scope)
error_message = "active_checks_scope should be one of: dev, testing, prod_quick, prod_acceptance, essential, cpu."
}
}

Expand Down
14 changes: 14 additions & 0 deletions soperator/modules/slurm/locals_active_checks.tf
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,20 @@ locals {
drainReasonPrefix = null
}
}
# Run only CPU-related validation checks
cpu = {
mem-perf = {}
ssh-check = {
k8sJobSpec = {
jobContainer = {
env = [{
name : "NUM_OF_LOGIN_NODES",
value : tostring(var.node_count.login)
}]
}
}
}
}
}

soperator_activechecks_override_yaml = yamlencode(local.active_checks_scopes[var.active_checks_scope])
Expand Down
4 changes: 2 additions & 2 deletions soperator/modules/slurm/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -734,8 +734,8 @@ variable "active_checks_scope" {
description = "Scope of active health-checks. Defines what checks should run after the cluster is provisioned."
default = ""
validation {
condition = contains(["dev", "testing", "prod_quick", "prod_acceptance", "essential"], var.active_checks_scope)
error_message = "active_checks_scope should be one of: dev, testing, prod_quick, prod_acceptance, essential."
condition = contains(["dev", "testing", "prod_quick", "prod_acceptance", "essential", "cpu"], var.active_checks_scope)
error_message = "active_checks_scope should be one of: dev, testing, prod_quick, prod_acceptance, essential, cpu."
}
}
# endregion ActiveChecks
Expand Down
Loading