From f4f7c74fd05f8725c86022cbeb0b0f71fdf223a6 Mon Sep 17 00:00:00 2001 From: Austin Macdonald Date: Mon, 9 Sep 2024 13:07:10 -0500 Subject: [PATCH] Add Workshop (on-demand) Profile Option --- addons.tf | 1 + envs/dandi-staging/managed-jupyterhub.yaml | 2 +- envs/shared/jupyterhub.yaml | 2 +- helm/karpenter-resources/templates/node-pool.yaml | 6 ++++-- 4 files changed, 7 insertions(+), 4 deletions(-) diff --git a/addons.tf b/addons.tf index df2d454e..42ae77e3 100644 --- a/addons.tf +++ b/addons.tf @@ -181,6 +181,7 @@ module "eks_blueprints_addons" { name: cpu-on-demand clusterName: ${module.eks.cluster_name} instanceSizes: ["xlarge", "2xlarge", "4xlarge", "8xlarge", "16xlarge", "24xlarge"] + instanceFamilies: ["c5", "m5", "r5"] karpenterRole: ${split("/", module.eks_blueprints_addons.karpenter.node_iam_role_arn)[1]} capacityTypes: ["on-demand"] EOT diff --git a/envs/dandi-staging/managed-jupyterhub.yaml b/envs/dandi-staging/managed-jupyterhub.yaml index 8bacfbdf..a8ec95da 100644 --- a/envs/dandi-staging/managed-jupyterhub.yaml +++ b/envs/dandi-staging/managed-jupyterhub.yaml @@ -218,7 +218,7 @@ singleuser: display_name: Image - default: true description: 6 CPU / 16 GB up to 12C/32G. May take up to 15 mins to start. - display_name: Base On Demand + display_name: MIT Workshop (tmp) kubespawner_override: cpu_guarantee: 6 cpu_limit: 12 diff --git a/envs/shared/jupyterhub.yaml b/envs/shared/jupyterhub.yaml index 23d9dec7..8a066238 100755 --- a/envs/shared/jupyterhub.yaml +++ b/envs/shared/jupyterhub.yaml @@ -59,7 +59,7 @@ singleuser: mem_guarantee: 0.5G node_selector: NodePool: default - - display_name: "Base On Demand" + - display_name: "MIT Workshop (tmp)" description: "6 CPU / 16 GB up to 12C/32G. May take up to 15 mins to start." profile_options: image: diff --git a/helm/karpenter-resources/templates/node-pool.yaml b/helm/karpenter-resources/templates/node-pool.yaml index 57bcd94b..f5ad0a2f 100644 --- a/helm/karpenter-resources/templates/node-pool.yaml +++ b/helm/karpenter-resources/templates/node-pool.yaml @@ -38,8 +38,10 @@ spec: values: ["amd64"] - key: "karpenter.sh/capacity-type" operator: In - values: - - {{ .Values.capacityTypes }} + {{- with .Values.capacityTypes }} + values: + {{- toYaml . | nindent 12 }} + {{- end }} disruption: consolidationPolicy: WhenEmpty consolidateAfter: 30s