#!/bin/bash # Start Xvfb for virtual display Xvfb $DISPLAY -screen 0 1280x1024x16 & # Wait for Xvfb to start sleep 2 # Start Fluxbox as a minimal window manager fluxbox & # Start x11vnc with logging and retry mechanism x11vnc -display $DISPLAY -nopw -forever -shared -rfbport $VNC_PORT -o $X11VNC_LOG & # Wait for x11vnc to initialize sleep 2 # Start noVNC to provide web access /usr/share/novnc/utils/launch.sh --vnc localhost:$VNC_PORT --listen $NOVNC_PORT & # Start Brave Browser with DBUS disabled brave-browser --no-sandbox --display=$DISPLAY