ComfyUI: rootless-correct GPU group config (video only)

Rootless podman cannot map the 'render' gid (990) into the container
namespace (dank's subgid range is 100000+), so --group-add render fails to
start the container. GPU access actually comes from the /dev/kfd + /dev/dri
passthrough, checked host-side (the run user is already in 'render' on the
host). So add only the 'video' group (which resolves) and drop 'render'.

Update the group test to assert video present and render ABSENT (with the
rootless rationale), per the approved rootless config.
This commit is contained in:
Frank
2026-08-19 15:50:28 -07:00
parent 354ddc473f
commit 88dcd3cc0f
2 changed files with 13 additions and 6 deletions
+10 -4
View File
@@ -9,7 +9,8 @@
#
# STATUS (2026-08-19): the GPU migration is applied. The compose builds
# comfyui-rocm:gfx1151 from Containerfile.comfyui (AMD's gfx1151 torch base),
# passes /dev/kfd + /dev/dri, adds the video+render groups, and drops --cpu.
# passes /dev/kfd + /dev/dri, adds the video group (render is unmappable in
# rootless), and drops --cpu.
# The four compose-wiring tests below are active (un-skipped). See
# docs/Research/ComfyUI ROCm and Vulkan.md.
@@ -63,14 +64,19 @@ print("command OK:", cmd)
PYEOF
}
@test "comfyui adds the video and render groups" {
@test "comfyui adds the video group (render is unmappable in rootless)" {
python3 - "$REPO_ROOT/dankclaw/compose.yaml" <<'PYEOF'
import sys, yaml
with open(sys.argv[1]) as fh:
data = yaml.safe_load(fh)
groups = data["services"]["comfyui"].get("group_add", [])
for g in ("video", "render"):
assert g in groups, f"comfyui group_add must include {g}; got: {groups}"
# 'video' is added (it resolves in the rootless namespace). 'render' (gid 990)
# is intentionally ABSENT: rootless podman cannot map it into the container
# namespace (the subgid range is 100000+), so --group-add render fails to start.
# GPU access comes from the /dev/kfd + /dev/dri passthrough, checked host-side
# (the run user is already a member of 'render' on the host).
assert "video" in groups, f"comfyui group_add must include video; got: {groups}"
assert "render" not in groups, f"comfyui group_add must NOT include render (unmappable in rootless); got: {groups}"
print("groups OK:", groups)
PYEOF
}