Skip to content

Instantly share code, notes, and snippets.

@keepitsimple
Created March 23, 2016 15:26
Show Gist options
  • Save keepitsimple/1ea4307004b291d66d2d to your computer and use it in GitHub Desktop.
Save keepitsimple/1ea4307004b291d66d2d to your computer and use it in GitHub Desktop.
Docker: Firefox over VNC
# Firefox over VNC
#
# VERSION 0.3
FROM ubuntu
# Install vnc, xvfb in order to create a 'fake' display and firefox
RUN apt-get update && apt-get install -y x11vnc xvfb firefox
RUN mkdir ~/.vnc
# Setup a password
RUN x11vnc -storepasswd 1234 ~/.vnc/passwd
# Autostart firefox (might not be the best way, but it does the trick)
RUN bash -c 'echo "firefox" >> /.bashrc'
EXPOSE 5900
CMD ["x11vnc", "-forever", "-usepw", "-create"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment