Skip to content

Commit dd2d01f

Browse files
lukemarsdenclaude
andcommitted
Simplify AMD Wolf config and add uhid module auto-loading
Based on tested working AMD Wolf configuration, simplified docker-compose.yaml: 1. wolf-amd service (docker-compose.yaml:339-358): - REMOVED: security_opt: seccomp=unconfined (not needed) - REMOVED: group_add: video, render (not needed) - REMOVED: devices: /dev/kfd (already in /dev/ volume mount) - Kept: /dev/dri, /dev/uinput, /dev/uhid (explicit for clarity) - Note: /dev/:/dev/:rw volume mount provides all GPU access 2. runner.sh AMD flags (install.sh:2145): - REMOVED: --security-opt seccomp=unconfined - Kept: --device /dev/kfd --device /dev/dri (runners don't mount /dev/) - Kept: --group-add video --group-add render (for device access) 3. uhid kernel module auto-loading (install.sh:1309-1328): - Load uhid immediately: modprobe uhid - Configure auto-load on boot: /etc/modules-load.d/helix.conf - Required for Wolf virtual HID devices - Skipped on Git Bash (Windows doesn't have modprobe) Edge case: Both NVIDIA and AMD GPUs present - Priority: NVIDIA > AMD > Intel (if/elif logic) - Result: Uses NVIDIA GPU, ignores AMD - Reasonable: Can't use both simultaneously anyway 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
1 parent f68e894 commit dd2d01f

File tree

2 files changed

+24
-8
lines changed

2 files changed

+24
-8
lines changed

docker-compose.yaml

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -338,7 +338,6 @@ services:
338338
- 'c 13:* rmw'
339339
devices:
340340
- /dev/dri
341-
- /dev/kfd # AMD ROCm Kernel Fusion Driver
342341
- /dev/uinput
343342
- /dev/uhid
344343
ports:
@@ -350,12 +349,8 @@ services:
350349
- "47999:47999/udp" # Control
351350
- "48100:48100/udp" # Video RTP
352351
- "48200:48200/udp" # Audio RTP
353-
# No nvidia runtime for AMD - use device pass-through instead
354-
security_opt:
355-
- seccomp=unconfined # Required for AMD GPU access
356-
group_add:
357-
- video # Grant access to /dev/dri
358-
- render # Grant access to GPU rendering
352+
# No nvidia runtime for AMD - /dev/ volume mount provides GPU access
353+
# No seccomp=unconfined or group_add needed - /dev/ volume provides access
359354
cap_add:
360355
- SYS_PTRACE # Required to read /proc/<pid>/task/<tid>/syscall for thread diagnostics
361356
restart: unless-stopped

install.sh

Lines changed: 22 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1306,6 +1306,27 @@ if [ "$CODE" = true ] && [ "$RUNNER" = false ]; then
13061306
fi
13071307
fi
13081308

1309+
# Load uhid kernel module for Helix Code (required for virtual HID devices in Wolf)
1310+
if [ "$CODE" = true ]; then
1311+
echo "Loading uhid kernel module for virtual HID device support..."
1312+
if [ "$ENVIRONMENT" = "gitbash" ]; then
1313+
echo "Skipping uhid module loading on Windows Git Bash"
1314+
else
1315+
# Load module immediately
1316+
if sudo modprobe uhid 2>/dev/null; then
1317+
echo "✓ uhid module loaded"
1318+
else
1319+
echo "Warning: Failed to load uhid module - may already be loaded or built-in"
1320+
fi
1321+
1322+
# Make uhid auto-load on boot
1323+
if [ ! -f /etc/modules-load.d/helix.conf ] || ! grep -q "^uhid" /etc/modules-load.d/helix.conf; then
1324+
echo "uhid" | sudo tee -a /etc/modules-load.d/helix.conf > /dev/null
1325+
echo "✓ uhid module configured to auto-load on boot (/etc/modules-load.d/helix.conf)"
1326+
fi
1327+
fi
1328+
fi
1329+
13091330
# Create installation directories (platform-specific)
13101331
if [ "$ENVIRONMENT" = "gitbash" ]; then
13111332
mkdir -p "$INSTALL_DIR"
@@ -2121,7 +2142,7 @@ for i in \$(seq 1 \$SPLIT_RUNNERS); do
21212142
elif [ "\$GPU_VENDOR" = "amd" ]; then
21222143
# AMD: Use device pass-through + ROCR_VISIBLE_DEVICES env var
21232144
# Note: ROCR_VISIBLE_DEVICES uses GPU IDs (0,1,2) same as CUDA
2124-
GPU_FLAGS="--device /dev/kfd --device /dev/dri --group-add video --group-add render --security-opt seccomp=unconfined"
2145+
GPU_FLAGS="--device /dev/kfd --device /dev/dri --group-add video --group-add render"
21252146
ENV_FLAGS="-e ROCR_VISIBLE_DEVICES=\$GPU_DEVICES"
21262147
else
21272148
echo "Error: Unknown GPU_VENDOR: \$GPU_VENDOR"

0 commit comments

Comments
 (0)