Sample Header Ad - 728x90

Gqrx GUI not showing in Docker (Openbox + Xvfb + noVNC) on macOS host

1 vote
0 answers
23 views
### 📝 Body: I'm running **Gqrx SDR** inside a **Docker container** on my **local macOS** machine using: * Openbox for the window manager * Xvfb for the X11 display * x11vnc + noVNC to stream the GUI via browser * Docker Desktop on macOS as the host environment --- ### ✅ Working: * The container builds and runs successfully * http://localhost:6080 opens the noVNC interface * xterm and xeyes work and appear inside the noVNC desktop * openbox-session starts without issue * gqrx runs without crashing (just a PulseAudio warning) --- ### ❌ Problem: * **The Gqrx GUI never appears** in the noVNC browser window * gqrx doesn't crash or exit * Other X11 apps render correctly * I've tested both automatic and manual gqrx startup --- ### 🛠️ Environment: * macOS 14.x with Docker Desktop (Ubuntu 22.04 container) * Access via browser: http://localhost:6080 * Docker run:
docker run -it --rm \
    -p 6080:6080 \
    -v ~/gqrx_data/config:/home/appuser/.config/gqrx \
    -v ~/gqrx_data/recordings:/home/appuser/recordings \
    gqrx-openbox
--- ### 📄 Dockerfile:
FROM ubuntu:22.04

ENV DEBIAN_FRONTEND=noninteractive
ENV LANG=C.UTF-8 LC_ALL=C.UTF-8

RUN apt-get update && \
    apt-get install -y --no-install-recommends \
        gqrx-sdr openbox x11vnc xvfb xterm \
        python3-pip python3-xdg \
        wget curl xfonts-base fonts-dejavu \
        qt5-style-plugins bash && \
    apt-get clean && rm -rf /var/lib/apt/lists/*

RUN pip3 install websockify

RUN wget -qO- https://github.com/novnc/noVNC/archive/refs/heads/master.tar.gz  | tar xz -C /opt && \
    ln -s /opt/noVNC-master /opt/noVNC

RUN useradd -ms /bin/bash appuser
COPY start.sh /start.sh
RUN chmod +x /start.sh

USER appuser
WORKDIR /home/appuser

EXPOSE 6080

CMD ["/start.sh"]
--- ### 📄 start.sh:
#!/bin/bash

set -e

export DISPLAY=:1
export QT_QPA_PLATFORM=xcb
export QT_OPENGL=software
export QT_QPA_PLATFORMTHEME=gtk2
export LANG=C.UTF-8
export XDG_RUNTIME_DIR=/tmp/runtime-appuser
export PULSE_SERVER=127.0.0.1

mkdir -p $XDG_RUNTIME_DIR
chmod 700 $XDG_RUNTIME_DIR

echo "[+] Starting Xvfb..."
Xvfb :1 -screen 0 1920x1080x24 &
sleep 2

echo "[+] Starting Openbox..."
openbox-session &

echo "[+] Starting x11vnc..."
x11vnc -display :1 -nopw -forever -shared -bg

echo "[+] Starting noVNC..."
websockify --web=/opt/noVNC 6080 localhost:5900 &

echo "[+] Writing default Gqrx config..."
mkdir -p /home/appuser/.config/gqrx
if [ ! -f /home/appuser/.config/gqrx/default.conf ]; then
cat  /home/appuser/.config/gqrx/default.conf
[grc]
audio_backend=disabled
audio_input=null
EOF
fi

echo "[+] Launching Gqrx..."
gqrx &

xterm &
tail -f /dev/null
--- ### 🧪 Tried: * Verified xeyes and xterm render correctly * Manually launched Gqrx inside xterm * Set QT_DEBUG_PLUGINS=1 — Qt loads plugins fine * Checked DISPLAY=:1, XDG_RUNTIME_DIR, and permissions * Verified Qt uses xcb and software OpenGL * No error on Gqrx — but **GUI never appears** --- ### ❓Question: **Why would Gqrx fail to show its GUI window** inside a fully working Openbox + Xvfb + x11vnc + noVNC environment on macOS Docker, when everything else (like xterm, xeyes) works? Is there something special about Gqrx/Qt that could block it from rendering under Xvfb?
Asked by nick97 (11 rep)
Jun 10, 2025, 10:23 PM