Skip to content

Instantly share code, notes, and snippets.

@Earlopain
Last active February 24, 2024 17:31
Show Gist options
  • Save Earlopain/ca11fb68ad1e9eab57638d0f87a691f9 to your computer and use it in GitHub Desktop.
Save Earlopain/ca11fb68ad1e9eab57638d0f87a691f9 to your computer and use it in GitHub Desktop.
Try at a repro for selenium-docker + novnc hanging
FROM ubuntu:jammy-20231128
# No interactive frontend during docker build
ENV DEBIAN_FRONTEND=noninteractive \
DEBCONF_NONINTERACTIVE_SEEN=true
RUN apt-get update -qqy \
&& apt-get -qqy install \
x11vnc xvfb \
&& rm -rf /var/lib/apt/lists/* /var/cache/apt/*
RUN <<EOF cat >> /opt/entrypoint.sh
#!/bin/bash
/usr/bin/Xvfb :99 -listen tcp -screen 0 1360x1020x24 & \
sleep 1 && x11vnc -forever -rfbport 5900 -display :99.0 &
wait -n
exit $?
EOF
RUN chmod +x /opt/entrypoint.sh
CMD ["/opt/entrypoint.sh"]
EXPOSE 5900
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment