feat: update configs for host+VPS with Intel VirtualHeads and dummy driver
- Host: 20-intel-virtual.conf with Driver intel + VirtualHeads 1 - VPS: xorg-dummy.service + rustdesk-dummy.service for CPU-only - Updated README with dual setup (host Intel iGPU + VPS dummy) - Verified: VIRTUAL1 primary after reboot, HDMI1 clone - Verified: DUMMY0 primary on VPS without GPU
This commit is contained in:
31
bin/vps-start-xorg.sh
Executable file
31
bin/vps-start-xorg.sh
Executable file
@@ -0,0 +1,31 @@
|
||||
#!/bin/bash
|
||||
# Start Xorg with dummy driver for headless VPS
|
||||
export DISPLAY=:0
|
||||
export XAUTHORITY=${XAUTHORITY:-/run/user/0/.Xauthority}
|
||||
|
||||
# Generate MIT magic cookie if needed
|
||||
if [ ! -s "$XAUTHORITY" ]; then
|
||||
mkdir -p "$(dirname "$XAUTHORITY")"
|
||||
touch "$XAUTHORITY"
|
||||
xauth -f "$XAUTHORITY" generate :0 MIT-MAGIC-COOKIE-1 2>/dev/null || \
|
||||
xauth -f "$XAUTHORITY" add :0 MIT-MAGIC-COOKIE-1 "$(xxd -l 16 -p /dev/urandom)" 2>/dev/null || true
|
||||
fi
|
||||
|
||||
# Ensure socket directory
|
||||
mkdir -p /tmp/.X11-unix
|
||||
|
||||
# Check if already running
|
||||
if pgrep -x "Xorg" >/dev/null 2>&1; then
|
||||
echo "Xorg already running"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
exec /usr/lib/xorg/Xorg :0 \
|
||||
-nolisten tcp \
|
||||
-nolisten local \
|
||||
-config /etc/X11/xorg.conf.d/99-dummy.conf \
|
||||
+extension GLX \
|
||||
+extension RANDR \
|
||||
+extension RENDER \
|
||||
-novtswitch \
|
||||
-keeptty
|
||||
Reference in New Issue
Block a user