Add runtime status checker + headless/X11 docs; distro-support refinements

- status.sh: runtime health check (service state, boot wiring, display backend auto-detect, encoder, ports, web UI, /dev/uinput, pairing) ending in a g2g verdict or concrete TODO list

- docs: TROUBLESHOOTING §12 (headless graphical-session.target boot trap) + §13 (X11/NVENC path & stale wlr drop-in env conflict); ARCHITECTURE capture-backend comparison; FOLLOWUPS P3 (installer X11/Ubuntu support); README diagnostics pointer

- lib/{config,packages,permissions,service}.sh, files/sway-headless.service: in-progress Debian/Ubuntu + headless support refinements

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-06-02 22:57:03 +00:00
parent ee1379d5be
commit ab23107300
10 changed files with 623 additions and 38 deletions

View File

@@ -10,11 +10,21 @@ Type=simple
# Tell wlroots to use the headless backend (no DRM master needed) and skip
# libinput device probing — there are no input devices on a real headless box.
# The Vulkan renderer is preferred on NVIDIA + handles NVENC capture cleanly;
# wlroots falls back to GLES2 automatically if Vulkan isn't usable.
#
# GLES2 renderer: the Vulkan backend strictly requires
# VK_EXT_external_memory_dma_buf, which the proprietary NVIDIA driver
# doesn't expose on every build (esp. data-center / -server branches). GLES2
# is universally available and Sunshine's capture path uses its own dma-buf
# flow, so we don't lose hardware acceleration.
Environment=WLR_BACKENDS=headless
Environment=WLR_LIBINPUT_NO_DEVICES=1
Environment=WLR_RENDERER=vulkan
# Pixman (software) renderer. The GLES2 path needs a GBM-allocated framebuffer,
# which fails on the proprietary NVIDIA driver: its GBM bridge doesn't permit
# unprivileged CREATE_DUMB even on render nodes (Mesa drivers do). The trade-
# off: Sunshine's wlr-screencopy then takes the shm path and uses libx264
# software encoding. For NVENC on NVIDIA cloud GPUs, sunshine should be
# pointed at a virtual KMS connector (vkms or Xorg+Dummy) instead of wlroots.
Environment=WLR_RENDERER=pixman
Environment=XDG_SESSION_TYPE=wayland
ExecStart=/usr/bin/sway --config %h/.config/sway/config-headless --unsupported-gpu