|
| 1 | +# SPDX-FileCopyrightText: Copyright (c) 2025 NVIDIA CORPORATION & AFFILIATES. All rights reserved. |
| 2 | +# SPDX-License-Identifier: Apache-2.0 |
| 3 | + |
| 4 | +apiVersion: nvidia.com/v1alpha1 |
| 5 | +kind: DynamoGraphDeployment |
| 6 | +metadata: |
| 7 | + name: sglang-disagg-planner |
| 8 | + annotations: |
| 9 | + nvidia.com/enable-grove: "false" |
| 10 | +spec: |
| 11 | + envs: |
| 12 | + - name: DYNAMO_SERVICE_CONFIG |
| 13 | + value: '{"Prometheus":{"global":{"scrape_interval":"5s"},"scrape_configs":[{"job_name":"prometheus","static_configs":[{"targets":["localhost:9090"]}]},{"job_name":"frontend","static_configs":[{"targets":["sglang-disagg-planner-frontend:8000"]}]}]}}' |
| 14 | + - name: DYNAMO_NAMESPACE |
| 15 | + value: "dynamo" |
| 16 | + services: |
| 17 | + Frontend: |
| 18 | + dynamoNamespace: dynamo |
| 19 | + livenessProbe: |
| 20 | + httpGet: |
| 21 | + path: /health |
| 22 | + port: 8000 |
| 23 | + initialDelaySeconds: 20 |
| 24 | + periodSeconds: 5 |
| 25 | + timeoutSeconds: 5 |
| 26 | + failureThreshold: 3 |
| 27 | + readinessProbe: |
| 28 | + exec: |
| 29 | + command: |
| 30 | + - /bin/sh |
| 31 | + - -c |
| 32 | + - 'curl -s http://localhost:8000/health | jq -e ".status == \"healthy\""' |
| 33 | + initialDelaySeconds: 60 |
| 34 | + periodSeconds: 60 |
| 35 | + timeoutSeconds: 30 |
| 36 | + failureThreshold: 10 |
| 37 | + componentType: main |
| 38 | + replicas: 1 |
| 39 | + resources: |
| 40 | + requests: |
| 41 | + cpu: "10" |
| 42 | + memory: "10Gi" |
| 43 | + limits: |
| 44 | + cpu: "32" |
| 45 | + memory: "40Gi" |
| 46 | + extraPodSpec: |
| 47 | + mainContainer: |
| 48 | + image: nvcr.io/nvidian/nim-llm-dev/sglang-runtime:hzhou-0811-1 |
| 49 | + workingDir: /workspace/components/backends/sglang |
| 50 | + command: ["sh", "-c"] |
| 51 | + args: |
| 52 | + - "python3 -m dynamo.sglang.utils.clear_namespace --namespace sglang-disagg && python3 -m dynamo.frontend --http-port=8000" |
| 53 | + Planner: |
| 54 | + dynamoNamespace: dynamo |
| 55 | + envFromSecret: hf-token-secret |
| 56 | + componentType: planner |
| 57 | + replicas: 1 |
| 58 | + livenessProbe: |
| 59 | + exec: |
| 60 | + command: |
| 61 | + - /bin/sh |
| 62 | + - -c |
| 63 | + - "exit 0" |
| 64 | + periodSeconds: 60 |
| 65 | + timeoutSeconds: 30 |
| 66 | + failureThreshold: 10 |
| 67 | + readinessProbe: |
| 68 | + exec: |
| 69 | + command: |
| 70 | + - /bin/sh |
| 71 | + - -c |
| 72 | + - "exit 0" |
| 73 | + initialDelaySeconds: 60 |
| 74 | + periodSeconds: 60 |
| 75 | + timeoutSeconds: 30 |
| 76 | + failureThreshold: 10 |
| 77 | + resources: |
| 78 | + requests: |
| 79 | + cpu: "2" |
| 80 | + memory: "2Gi" |
| 81 | + limits: |
| 82 | + cpu: "8" |
| 83 | + memory: "16Gi" |
| 84 | + pvc: |
| 85 | + create: false |
| 86 | + name: profiling-pvc # Must be pre-created before deployment and SLA profiler must have been run |
| 87 | + mountPoint: /workspace/profiling_results |
| 88 | + extraPodSpec: |
| 89 | + mainContainer: |
| 90 | + image: nvcr.io/nvidian/nim-llm-dev/sglang-runtime:hzhou-0811-1 |
| 91 | + workingDir: /workspace/components/planner/src/dynamo/planner |
| 92 | + args: |
| 93 | + - python |
| 94 | + - -m |
| 95 | + - planner_sla |
| 96 | + - --environment=kubernetes |
| 97 | + - --backend=sglang |
| 98 | + - --adjustment-interval=60 |
| 99 | + - --profile-results-dir=/workspace/profiling_results |
| 100 | + Prometheus: |
| 101 | + dynamoNamespace: dynamo |
| 102 | + componentType: main |
| 103 | + replicas: 1 |
| 104 | + envs: |
| 105 | + - name: PYTHONPATH |
| 106 | + value: "/workspace/components/planner/src" |
| 107 | + livenessProbe: |
| 108 | + exec: |
| 109 | + command: |
| 110 | + - /bin/sh |
| 111 | + - -c |
| 112 | + - "exit 0" |
| 113 | + periodSeconds: 60 |
| 114 | + timeoutSeconds: 30 |
| 115 | + failureThreshold: 10 |
| 116 | + readinessProbe: |
| 117 | + exec: |
| 118 | + command: |
| 119 | + - /bin/sh |
| 120 | + - -c |
| 121 | + - "exit 0" |
| 122 | + initialDelaySeconds: 30 |
| 123 | + periodSeconds: 60 |
| 124 | + timeoutSeconds: 30 |
| 125 | + failureThreshold: 10 |
| 126 | + resources: |
| 127 | + requests: |
| 128 | + cpu: "2" |
| 129 | + memory: "2Gi" |
| 130 | + limits: |
| 131 | + cpu: "8" |
| 132 | + memory: "16Gi" |
| 133 | + extraPodSpec: |
| 134 | + mainContainer: |
| 135 | + image: nvcr.io/nvidian/nim-llm-dev/sglang-runtime:hzhou-0811-1 |
| 136 | + workingDir: /workspace/components/backends/sglang |
| 137 | + command: |
| 138 | + - /bin/sh |
| 139 | + - -c |
| 140 | + args: |
| 141 | + - "python3 -m dynamo.planner.prometheus" |
| 142 | + SGLangDecodeWorker: |
| 143 | + dynamoNamespace: dynamo |
| 144 | + envFromSecret: hf-token-secret |
| 145 | + livenessProbe: |
| 146 | + httpGet: |
| 147 | + path: /live |
| 148 | + port: 9090 |
| 149 | + periodSeconds: 5 |
| 150 | + timeoutSeconds: 30 |
| 151 | + failureThreshold: 1 |
| 152 | + readinessProbe: |
| 153 | + httpGet: |
| 154 | + path: /health |
| 155 | + port: 9090 |
| 156 | + periodSeconds: 10 |
| 157 | + timeoutSeconds: 30 |
| 158 | + failureThreshold: 60 |
| 159 | + componentType: worker |
| 160 | + replicas: 2 |
| 161 | + resources: |
| 162 | + requests: |
| 163 | + cpu: "10" |
| 164 | + memory: "20Gi" |
| 165 | + gpu: "1" |
| 166 | + limits: |
| 167 | + cpu: "32" |
| 168 | + memory: "80Gi" |
| 169 | + gpu: "1" |
| 170 | + envs: |
| 171 | + - name: DYN_SYSTEM_ENABLED |
| 172 | + value: "true" |
| 173 | + - name: DYN_SYSTEM_USE_ENDPOINT_HEALTH_STATUS |
| 174 | + value: "[\"generate\"]" |
| 175 | + - name: DYN_SYSTEM_PORT |
| 176 | + value: "9090" |
| 177 | + extraPodSpec: |
| 178 | + mainContainer: |
| 179 | + startupProbe: |
| 180 | + httpGet: |
| 181 | + path: /live |
| 182 | + port: 9090 |
| 183 | + periodSeconds: 10 |
| 184 | + failureThreshold: 60 |
| 185 | + image: nvcr.io/nvidian/nim-llm-dev/sglang-runtime:hzhou-0811-1 |
| 186 | + workingDir: /workspace/components/backends/sglang |
| 187 | + args: |
| 188 | + - "python3" |
| 189 | + - "-m" |
| 190 | + - "dynamo.sglang.decode_worker" |
| 191 | + - "--model-path" |
| 192 | + - "deepseek-ai/DeepSeek-R1-Distill-Llama-8B" |
| 193 | + - "--served-model-name" |
| 194 | + - "deepseek-ai/DeepSeek-R1-Distill-Llama-8B" |
| 195 | + - "--page-size" |
| 196 | + - "16" |
| 197 | + - "--tp" |
| 198 | + - "1" |
| 199 | + - "--trust-remote-code" |
| 200 | + - "--skip-tokenizer-init" |
| 201 | + - "--disaggregation-mode" |
| 202 | + - "decode" |
| 203 | + - "--disaggregation-transfer-backend" |
| 204 | + - "nixl" |
| 205 | + SGLangPrefillWorker: |
| 206 | + dynamoNamespace: dynamo |
| 207 | + envFromSecret: hf-token-secret |
| 208 | + livenessProbe: |
| 209 | + httpGet: |
| 210 | + path: /live |
| 211 | + port: 9090 |
| 212 | + periodSeconds: 5 |
| 213 | + timeoutSeconds: 30 |
| 214 | + failureThreshold: 1 |
| 215 | + readinessProbe: |
| 216 | + httpGet: |
| 217 | + path: /health |
| 218 | + port: 9090 |
| 219 | + periodSeconds: 10 |
| 220 | + timeoutSeconds: 30 |
| 221 | + failureThreshold: 60 |
| 222 | + componentType: worker |
| 223 | + replicas: 2 |
| 224 | + resources: |
| 225 | + requests: |
| 226 | + cpu: "10" |
| 227 | + memory: "20Gi" |
| 228 | + gpu: "1" |
| 229 | + limits: |
| 230 | + cpu: "32" |
| 231 | + memory: "80Gi" |
| 232 | + gpu: "1" |
| 233 | + envs: |
| 234 | + - name: DYN_SYSTEM_ENABLED |
| 235 | + value: "true" |
| 236 | + - name: DYN_SYSTEM_USE_ENDPOINT_HEALTH_STATUS |
| 237 | + value: "[\"generate\"]" |
| 238 | + - name: DYN_SYSTEM_PORT |
| 239 | + value: "9090" |
| 240 | + extraPodSpec: |
| 241 | + mainContainer: |
| 242 | + startupProbe: |
| 243 | + httpGet: |
| 244 | + path: /health |
| 245 | + port: 9090 |
| 246 | + periodSeconds: 10 |
| 247 | + failureThreshold: 60 |
| 248 | + image: nvcr.io/nvidian/nim-llm-dev/sglang-runtime:hzhou-0811-1 |
| 249 | + workingDir: /workspace/components/backends/sglang |
| 250 | + args: |
| 251 | + - "python3" |
| 252 | + - "-m" |
| 253 | + - "dynamo.sglang.worker" |
| 254 | + - "--model-path" |
| 255 | + - "deepseek-ai/DeepSeek-R1-Distill-Llama-8B" |
| 256 | + - "--served-model-name" |
| 257 | + - "deepseek-ai/DeepSeek-R1-Distill-Llama-8B" |
| 258 | + - "--page-size" |
| 259 | + - "16" |
| 260 | + - "--tp" |
| 261 | + - "1" |
| 262 | + - "--trust-remote-code" |
| 263 | + - "--skip-tokenizer-init" |
| 264 | + - "--disaggregation-mode" |
| 265 | + - "prefill" |
| 266 | + - "--disaggregation-transfer-backend" |
| 267 | + - "nixl" |
0 commit comments