petersweb-infra/nixos/vnc-desktop/Dockerfile
Philip Peterson 1334de7ff6 Add Discover logging patch and Firefox to vnc-desktop image
Adds a discover-logging/ build step that fetches the plasma-discover
source, instruments PKTransaction.cpp with qWarning calls at key points
(trigger, statusChanged, progressChanged, cleanup, errorFound,
installFile) to diagnose hanging .deb installs, then rebuilds and
reinstalls the patched packagekit-backend.so.

Also installs Firefox via the Mozilla apt repo (Ubuntu 24.04 ships
Firefox as a snap which doesn't work in the container).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-30 02:48:46 -08:00

45 lines
1.6 KiB
Docker

FROM ubuntu:24.04
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y \
tigervnc-standalone-server \
tigervnc-common \
novnc \
python3-websockify \
kde-plasma-desktop \
konsole \
x11-utils \
xfonts-base \
dbus-x11 \
openssh-client \
curl \
&& rm -rf /var/lib/apt/lists/*
# Remove Bluetooth stack — obexd gets activated in a tight loop by kded5
# inside the container (no BT hardware), which exhausts the process limit.
RUN apt-get purge -y --auto-remove bluez bluez-obexd 2>/dev/null || true; \
rm -f /usr/share/dbus-1/services/org.bluez.obex.service \
/usr/share/dbus-1/system-services/org.bluez.service
# Firefox via Mozilla apt repo (Ubuntu 24.04 ships Firefox as snap by default)
RUN apt-get install -y --no-install-recommends wget ca-certificates gnupg \
&& wget -qO- https://packages.mozilla.org/apt/repo-signing-key.gpg \
| gpg --dearmor > /usr/share/keyrings/packages.mozilla.org.gpg \
&& echo "deb [signed-by=/usr/share/keyrings/packages.mozilla.org.gpg] https://packages.mozilla.org/apt mozilla main" \
> /etc/apt/sources.list.d/mozilla.list \
&& printf 'Package: *\nPin: origin packages.mozilla.org\nPin-Priority: 1000\n' \
> /etc/apt/preferences.d/mozilla \
&& apt-get update \
&& apt-get install -y --no-install-recommends firefox \
&& rm -rf /var/lib/apt/lists/*
COPY discover-logging/ /discover-logging/
RUN chmod +x /discover-logging/build.sh && /discover-logging/build.sh
COPY start.sh /start.sh
RUN chmod +x /start.sh
EXPOSE 6080
CMD ["/start.sh"]