Skip to content

docs(tutorials): add Lab 11 — Run SGLang on HAMi GPU Shares#654

Open
rudrakshkarpe wants to merge 3 commits into
Project-HAMi:masterfrom
rudrakshkarpe:lab/sglang-on-hami
Open

docs(tutorials): add Lab 11 — Run SGLang on HAMi GPU Shares#654
rudrakshkarpe wants to merge 3 commits into
Project-HAMi:masterfrom
rudrakshkarpe:lab/sglang-on-hami

Conversation

@rudrakshkarpe

@rudrakshkarpe rudrakshkarpe commented Jul 23, 2026

Copy link
Copy Markdown

What type of PR is this?

/kind documentation

What this PR does / why we need it:

Adds Lab 11: Run SGLang on HAMi GPU Shares — a new intermediate tutorial that installs HAMi on an existing NVIDIA GPU cluster and schedules an SGLang inference service on a HAMi GPU share. It is the SGLang counterpart to the existing Lab 6 (vLLM), following the same structure so the two read as a pair.

The lab walks through:

  • Checking GPU-cluster prerequisites and labelling GPU nodes (gpu=on)
  • Installing the HAMi scheduler + device plugin (with a values file registering each GPU as 10 vGPUs)
  • Deploying Qwen3-1.7B with SGLang using nvidia.com/gpu, nvidia.com/gpumem (25000 MiB), and nvidia.com/gpucores (30%)
  • Testing the OpenAI-compatible API (/v1/models, /v1/chat/completions) via port-forward
  • Verifying the gpumem cap is enforced inside the Pod (nvidia-smi shows the ~25000 MiB slice while the host still reports the full 81559 MiB H100)

Manifests are inline (self-contained kubectl apply -f - blocks), and every command/output is captured from a verification run on a kind cluster backed by a single NVIDIA H100 80GB (verified: 2026-07-23).

Also adds the sidebar entry in sidebars-tutorials.js. The overview page picks the lab card up automatically from frontmatter via LabCardGridAuto.

Which issue(s) this PR fixes:

Fixes #528

Checklist:

  • npm run lint and npm run format:check pass
  • npm run build succeeds for both en and zh
  • Chinese translation updated if English docs changed (or noted why not)
  • Commits are signed off (git commit -s)

Notes for reviewers:

  • Chinese translation not yet added — happy to follow up under i18n/zh/.../labs/ once the English lab is reviewed (kept as a separate change to keep this PR focused).
  • Opened as a draft pending a local npm run build/lint pass; will mark ready once the checklist above is green.
  • cc @shivaylamba (issue author, co-author on this lab).

Summary by CodeRabbit

  • New Features
    • Added Lab 11, a hands-on tutorial for running SGLang inference services with HAMi GPU sharing.
    • Covers prerequisites, HAMi installation, GPU partitioning, service deployment, API testing, resource verification, troubleshooting, cleanup, and scaling guidance.
    • Added the tutorial to the Labs documentation sidebar with intermediate difficulty and an estimated duration of 45 minutes.

rudrakshkarpe and others added 2 commits July 24, 2026 03:52
Add a new intermediate lab that installs HAMi on an existing NVIDIA GPU
cluster and schedules an SGLang inference service on a HAMi GPU share.
The lab is the SGLang counterpart to Lab 6 (vLLM): it walks through the
HAMi install, deploys Qwen3-1.7B with nvidia.com/gpu, nvidia.com/gpumem
and nvidia.com/gpucores caps, tests the OpenAI-compatible API, and
verifies that the gpumem cap is enforced inside the Pod.

All commands and outputs are captured from a verification run on a kind
cluster backed by a single NVIDIA H100 80GB.

Addresses Project-HAMi#528

Co-authored-by: Shivay Lamba <19529592+shivaylamba@users.noreply.github.com>
Signed-off-by: rudrakshkarpe <rudraksh.karpe@gmail.com>
Add the labs/hami-sglang entry to sidebars-tutorials.js so the new lab
appears in the Labs category navigation.

Co-authored-by: Shivay Lamba <19529592+shivaylamba@users.noreply.github.com>
Signed-off-by: rudrakshkarpe <rudraksh.karpe@gmail.com>
@hami-robot

hami-robot Bot commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

@rudrakshkarpe: The label(s) kind/documentation cannot be applied, because the repository doesn't have them.

Details

In response to this:

What type of PR is this?

/kind documentation

What this PR does / why we need it:

Adds Lab 11: Run SGLang on HAMi GPU Shares — a new intermediate tutorial that installs HAMi on an existing NVIDIA GPU cluster and schedules an SGLang inference service on a HAMi GPU share. It is the SGLang counterpart to the existing Lab 6 (vLLM), following the same structure so the two read as a pair.

The lab walks through:

  • Checking GPU-cluster prerequisites and labelling GPU nodes (gpu=on)
  • Installing the HAMi scheduler + device plugin (with a values file registering each GPU as 10 vGPUs)
  • Deploying Qwen3-1.7B with SGLang using nvidia.com/gpu, nvidia.com/gpumem (25000 MiB), and nvidia.com/gpucores (30%)
  • Testing the OpenAI-compatible API (/v1/models, /v1/chat/completions) via port-forward
  • Verifying the gpumem cap is enforced inside the Pod (nvidia-smi shows the ~25000 MiB slice while the host still reports the full 81559 MiB H100)

Manifests are inline (self-contained kubectl apply -f - blocks), and every command/output is captured from a verification run on a kind cluster backed by a single NVIDIA H100 80GB (verified: 2026-07-23).

Also adds the sidebar entry in sidebars-tutorials.js. The overview page picks the lab card up automatically from frontmatter via LabCardGridAuto.

Which issue(s) this PR fixes:

Fixes #528

Checklist:

  • npm run lint and npm run format:check pass
  • npm run build succeeds for both en and zh
  • Chinese translation updated if English docs changed (or noted why not)
  • Commits are signed off (git commit -s)

Notes for reviewers:

  • Chinese translation not yet added — happy to follow up under i18n/zh/.../labs/ once the English lab is reviewed (kept as a separate change to keep this PR focused).
  • Opened as a draft pending a local npm run build/lint pass; will mark ready once the checklist above is green.
  • cc @shivaylamba (issue author, co-author on this lab).

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@netlify

netlify Bot commented Jul 23, 2026

Copy link
Copy Markdown

Deploy Preview for project-hami ready!

Name Link
🔨 Latest commit 74654fa
🔍 Latest deploy log https://app.netlify.com/projects/project-hami/deploys/6a6299a1f5cbf80008f897ce
😎 Deploy Preview https://deploy-preview-654--project-hami.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

@hami-robot
hami-robot Bot requested a review from archlitchi July 23, 2026 22:24
@hami-robot

hami-robot Bot commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: rudrakshkarpe
Once this PR has been reviewed and has the lgtm label, please assign windsonsea for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@hami-robot
hami-robot Bot requested a review from wawa0210 July 23, 2026 22:24
@coderabbitai

coderabbitai Bot commented Jul 23, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

Adds Lab 11 to the tutorials sidebar and introduces a complete guide for installing HAMi, deploying SGLang with GPU-share limits, testing its OpenAI-compatible API, validating enforcement, troubleshooting, and cleanup.

Changes

HAMi SGLang lab

Layer / File(s) Summary
Lab publication and learning path
sidebars-tutorials.js, tutorials/labs/hami-sglang.md
Registers the new intermediate lab and documents its objectives, diagrams, prerequisites, and expected cluster state.
HAMi installation and resource verification
tutorials/labs/hami-sglang.md
Documents GPU node labeling, pinned Helm installation, HAMi configuration, rollout checks, and advertised GPU-share resources.
SGLang deployment and validation
tutorials/labs/hami-sglang.md
Deploys SGLang with HAMi resource caps, tests API endpoints, verifies in-container GPU limits, and adds troubleshooting, cleanup, results, and next steps.

Estimated code review effort: 2 (Simple) | ~10 minutes

Sequence Diagram(s)

sequenceDiagram
  participant Client
  participant SGLangService
  participant SGLangPod
  participant HAMiScheduler
  Client->>SGLangService: request OpenAI-compatible API
  SGLangService->>SGLangPod: forward request
  HAMiScheduler->>SGLangPod: apply GPU-share limits
  SGLangPod-->>SGLangService: return inference response
  SGLangService-->>Client: return response
Loading

Possibly related PRs

Suggested labels: enhancement

Suggested reviewers: wawa0210, archlitchi, windsonsea, rootsongjc

Poem

I’m a rabbit with GPUs in my burrow tonight,
HAMi shares the carrots just right.
SGLang hops, APIs sing,
Capped little kernels do their thing.
Clean up the meadow—what a delight!

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the main change: adding a Lab 11 tutorial for running SGLang on HAMi GPU shares.
Linked Issues check ✅ Passed The PR fulfills #528 by adding a tutorial that installs HAMi on an NVIDIA-GPU Kubernetes cluster and schedules an SGLang inference service.
Out of Scope Changes check ✅ Passed The changes stay within scope of the lab and sidebar update, with no obvious unrelated code or feature additions.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@hami-robot hami-robot Bot added the size/XL label Jul 23, 2026
The "Next Steps" section linked to ./hami-kitops (Lab 12), which does not
exist on master yet, so `docusaurus build` failed its broken-link check.
Point at the tracking issue (website#561) instead, keeping this lab
self-contained and independently buildable.

Co-authored-by: Shivay Lamba <19529592+shivaylamba@users.noreply.github.com>
Signed-off-by: rudrakshkarpe <rudraksh.karpe@gmail.com>
@rudrakshkarpe
rudrakshkarpe marked this pull request as ready for review July 23, 2026 22:48
@hami-robot
hami-robot Bot requested a review from mesutoezdil July 23, 2026 22:48
@coderabbitai
coderabbitai Bot requested review from rootsongjc and windsonsea July 23, 2026 22:49
@coderabbitai coderabbitai Bot added the enhancement New feature or request label Jul 23, 2026

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 5

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@tutorials/labs/hami-sglang.md`:
- Around line 526-530: Update the cleanup instructions around the kubectl label
command to remove gpu=on only when this lab added it. Have users record the node
label’s prior state before applying changes, and preserve the label when it
already existed so other workloads or DaemonSets are unaffected.
- Around line 137-143: The HAMi setup instructions must explicitly prevent
coexistence with the vendor NVIDIA device plugin. Update the surrounding
installation section to instruct users to disable or remove the NVIDIA device
plugin while retaining NVIDIA drivers/runtime support, and add cleanup
instructions for restoring or reinstalling the vendor plugin after HAMi is
removed.
- Around line 72-73: Update the GPU prerequisite in the lab guide to remove the
claim that an A10 works with the current configuration; either require GPUs with
at least 25,000 MiB of VRAM or document an A10-specific lower gpumem value
matching the manifest requirements.
- Around line 274-275: Update the SGLang image reference in the Kubernetes
example to the exact tested version tag or immutable digest instead of
lmsysorg/sglang:latest, preserving the existing imagePullPolicy unless required
otherwise. Apply the same pinned reference to the corresponding English example
and Chinese mirror if present.
- Around line 20-31: Update the HAMi verification sections around the in-pod
nvidia-smi checks and the corresponding evidence summary to describe soft
CUDA/NVML-level isolation rather than a hard GPU memory cap. Add an over-quota
CUDA allocation test that requests memory beyond the configured 25000MiB limit
and explicitly expects CUDA_ERROR_OUT_OF_MEMORY, while retaining the quota
visibility check as supporting evidence. Apply the same terminology and
validation behavior to the sections covering the later verification and
conclusion steps.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: f86ad967-4005-4f92-ad3c-a21ad6fbe64c

📥 Commits

Reviewing files that changed from the base of the PR and between f4db4f8 and 74654fa.

📒 Files selected for processing (2)
  • sidebars-tutorials.js
  • tutorials/labs/hami-sglang.md

Comment on lines +20 to +31
This lab demonstrates how to install HAMi on a Kubernetes cluster that already has NVIDIA GPUs, and use HAMi to schedule an [SGLang](https://github.com/sgl-project/sglang) inference service. Upon completion, you will have an OpenAI-compatible model service that can be verified through `/v1/models` and `/v1/chat/completions`, with HAMi enforcing GPU memory and compute caps inside the Pod.

This guide is modeled after [Lab 6: Run vLLM on HAMi GPU Shares](./hami-vllm). The steps are not tied to a specific cloud vendor. As long as your Kubernetes cluster has available NVIDIA GPUs, NVIDIA drivers, and container runtime support, you can reproduce the same setup.

## Learning Objectives

- Verify that an existing GPU Kubernetes cluster meets the prerequisites for HAMi and SGLang
- Install HAMi scheduler and device plugin
- Add labels required by the HAMi DaemonSet to GPU nodes
- Run SGLang using HAMi's `nvidia.com/gpu`, `nvidia.com/gpumem`, and `nvidia.com/gpucores` resources
- Test the SGLang OpenAI-compatible API via port forwarding
- Confirm that `nvidia.com/gpumem` is enforced inside the SGLang Pod

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔒 Security & Privacy | 🟠 Major | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "=== file line count and relevant snippets ==="
wc -l tutorials/labs/hami-sglang.md
printf '\n--- lines 1-50 ---\n'
sed -n '1,70p' tutorials/labs/hami-sglang.md
printf '\n--- lines 310-360 ---\n'
sed -n '310,360p' tutorials/labs/hami-sglang.md
printf '\n--- lines 440-500 ---\n'
sed -n '440,500p' tutorials/labs/hami-sglang.md
printf '\n--- lines 515-550 ---\n'
sed -n '515,550p' tutorials/labs/hami-sglang.md

printf '\n=== search for relevant terms ===\n'
rg -n "hard|quota|25000MiB|nvidia-smi|CUDA OOM|soft|HAMi|nvidia.com/gpumem|over-limit|allocation|enforced" tutorials/labs/hami-sglang.md

Repository: Project-HAMi/website

Length of output: 13544


🌐 Web query:

HAMi FAQ soft isolation CUDA API nvidia-smi quota

💡 Result:

HAMi provides GPU virtualization and resource isolation for Kubernetes using a user-space library interception mechanism, rather than kernel-level drivers or hardware partitions [1][2][3]. Core Mechanisms and Isolation HAMi injects a shared library, libvgpu.so, into containers via /etc/ld.so.preload [1][4][2]. This library intercepts CUDA and NVML API calls to enforce limits at the runtime level [2]. 1. Memory Isolation: HAMi enforces a hard limit on VRAM usage [2][5]. When an application attempts to allocate memory, libvgpu.so checks the request against the nvidia.com/gpumem quota [2][6]. If the request exceeds the remaining budget, the library returns a CUDA_ERROR_OUT_OF_MEMORY to the application, preventing it from exceeding its allocated slice [1][2][6]. 2. Compute Isolation: HAMi applies a soft compute limit using a token-bucket throttle mechanism embedded within libvgpu.so [1][4][5]. This controls the rate of kernel launch calls to cap compute usage at the requested percentage (nvidia.com/gpucores), acting as a rate limit rather than hardware-enforced isolation [2][5]. Interaction with nvidia-smi and CUDA - nvidia-smi: Because libvgpu.so intercepts NVML calls (e.g., nvmlDeviceGetMemoryInfo), nvidia-smi inside the container reports the virtualized quota (the HAMi limit) rather than the physical VRAM of the GPU [1][4][2]. The host-side nvidia-smi continues to report the physical memory and actual utilization [1][2]. - Bypassing Isolation: Limits may fail to enforce if the application bypasses the standard CUDA/NVML libraries, runs in Docker-in-Docker, or if the environment variable CUDA_DISABLE_CONTROL is set to true [1][4][3]. Comparison to Hardware Solutions Unlike NVIDIA MIG, which creates hardware-enforced partitions at the GPU engine level, HAMi’s memory enforcement is enforced at the CUDA API layer, and compute enforcement is a software-based throttle [1][4][5]. This makes HAMi flexible, allowing dynamic reconfiguration without node drains, but it provides "best-effort" multi-tenant noise isolation compared to the "strong" isolation of hardware-based methods [1][4].

Citations:


Clarify HAMi’s soft isolation instead of showing only quota reporting.

HAMi enforces limits at the CUDA/NVML interception layer, so in-pod nvidia-smi showing 25000MiB proves the visible quota; it does not demonstrate that over-quota allocations fail. Add an over-limit allocation step expecting CUDA_ERROR_OUT_OF_MEMORY, and replace “Hard GPU memory cap” / “key evidence” with wording that reflects CUDA-level enforcement.

Also applies to lines 335-344, 466-490, and 532-540.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@tutorials/labs/hami-sglang.md` around lines 20 - 31, Update the HAMi
verification sections around the in-pod nvidia-smi checks and the corresponding
evidence summary to describe soft CUDA/NVML-level isolation rather than a hard
GPU memory cap. Add an over-quota CUDA allocation test that requests memory
beyond the configured 25000MiB limit and explicitly expects
CUDA_ERROR_OUT_OF_MEMORY, while retaining the quota visibility check as
supporting evidence. Apply the same terminology and validation behavior to the
sections covering the later verification and conclusion steps.

Source: MCP tools

Comment on lines +72 to +73
- A working Kubernetes cluster
- At least 1 NVIDIA GPU node with enough free memory for the model (this guide uses a single NVIDIA H100 80GB; an A10/L40S-class GPU also works if you keep the small model and `gpumem` values)

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟠 Major | ⚡ Quick win

Fix the A10 compatibility claim.

The manifest later requests nvidia.com/gpumem: "25000", but an NVIDIA A10 has 24 GB of memory; HAMi rejects requests that exceed available physical VRAM. Restrict this lab to GPUs with at least 25,000 MiB or provide a lower A10-specific memory value. (nvidia.com)

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@tutorials/labs/hami-sglang.md` around lines 72 - 73, Update the GPU
prerequisite in the lab guide to remove the claim that an A10 works with the
current configuration; either require GPUs with at least 25,000 MiB of VRAM or
document an A10-specific lower gpumem value matching the manifest requirements.

Source: MCP tools

Comment on lines +137 to +143
If the cluster already has a vendor NVIDIA device plugin installed, you may already see `nvidia.com/gpu`. After installing HAMi, `nvidia.com/gpu` becomes the number of vGPUs exposed by HAMi.

HAMi's device plugin matches `gpu=on` when managed node selectors are enabled. Label your GPU nodes:

```bash
kubectl label node <gpu-node-name> gpu=on --overwrite
```

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🩺 Stability & Availability | 🟠 Major | 🏗️ Heavy lift

Do not run HAMi alongside the existing NVIDIA device plugin.

The current wording treats an existing nvidia.com/gpu provider as harmless, but HAMi’s device plugin and NVIDIA’s official device plugin must not coexist because both register the same resource. Add an explicit migration step to disable/remove the vendor device plugin while retaining drivers/runtime support, and document how to restore it during cleanup. (project-hami.io)

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@tutorials/labs/hami-sglang.md` around lines 137 - 143, The HAMi setup
instructions must explicitly prevent coexistence with the vendor NVIDIA device
plugin. Update the surrounding installation section to instruct users to disable
or remove the NVIDIA device plugin while retaining NVIDIA drivers/runtime
support, and add cleanup instructions for restoring or reinstalling the vendor
plugin after HAMi is removed.

Source: MCP tools

Comment on lines +274 to +275
image: lmsysorg/sglang:latest
imagePullPolicy: IfNotPresent

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🩺 Stability & Availability | 🟠 Major | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== locate file =="
git ls-files | rg '(^|/)hami-sglang\.md$|tutorials|labs' || true

echo "== relevant lines =="
if [ -f tutorials/labs/hami-sglang.md ]; then
  nl -ba tutorials/labs/hami-sglang.md | sed -n '230,300p'
fi

echo "== image references in file =="
if [ -f tutorials/labs/hami-sglang.md ]; then
  rg -n 'image:|imagePullPolicy|latest|sha256:|digest' tutorials/labs/hami-sglang.md
fi

echo "== surrounding docs config/sidebar =="
fd -a 'sidebar\.js|sidebar\.ts|sidebars\.js|sidebars\.ts' . -t f
rg -l 'hami-sglang|SGLang|hami' . || true

Repository: Project-HAMi/website

Length of output: 4094


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== relevant lines =="
awk 'NR>=230 && NR<=320 { printf "%5d\t%s\n", NR, $0 }' tutorials/labs/hami-sglang.md

echo "== image references =="
grep -En 'image:|imagePullPolicy|latest|sha256:|digest|SGLang|sglang' tutorials/labs/hami-sglang.md || true

echo "== translate source references and Chinese mirror =="
for f in $(git ls-files | grep -E '(^|/)hami-sglang\.md$|Chinese translation'); do
  echo "-- $f"
  grep -En 'image:|imagePullPolicy|latest|sha256:|digest|LMSYS|SGLang|sglang' "$f" || true
done

Repository: Project-HAMi/website

Length of output: 12428


Pin the SGLang image to a concrete version or digest.

lmsysorg/sglang:latest with IfNotPresent allows cached images to be reused and fresh nodes to resolve latest independently, so the captured lab outputs may not match what later runs execute. Use the exact tested tag/digest in tutorials/labs/hami-sglang.md and update the English example plus its Chinese mirror if present.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@tutorials/labs/hami-sglang.md` around lines 274 - 275, Update the SGLang
image reference in the Kubernetes example to the exact tested version tag or
immutable digest instead of lmsysorg/sglang:latest, preserving the existing
imagePullPolicy unless required otherwise. Apply the same pinned reference to
the corresponding English example and Chinese mirror if present.

Source: MCP tools

Comment on lines +526 to +530
Optional label cleanup:

```bash
kubectl label node <gpu-node-name> gpu-
```

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🩺 Stability & Availability | 🟡 Minor | ⚡ Quick win

Only remove gpu=on if this lab added it.

On an existing cluster, the label may be used by other workloads or DaemonSets. Record its prior state and avoid unconditionally deleting it during cleanup.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@tutorials/labs/hami-sglang.md` around lines 526 - 530, Update the cleanup
instructions around the kubectl label command to remove gpu=on only when this
lab added it. Have users record the node label’s prior state before applying
changes, and preserve the label when it already existed so other workloads or
DaemonSets are unaffected.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add a lab for Run SGLang on HAMi GPU Shares

1 participant