Skip to content

Instantly share code, notes, and snippets.

@pop
Last active February 5, 2016 07:51
Show Gist options
  • Save pop/29e7e829341d58abe370 to your computer and use it in GitHub Desktop.
Save pop/29e7e829341d58abe370 to your computer and use it in GitHub Desktop.
"You got Firefox in my Docker!"
FROM debian:latest
RUN apt-get update
RUN apt-get -y install iceweasel
ENV DISPLAY :0
CMD iceweasel
#!/bin/bash
SETUP_DIR=$HOME/bin/docker-firefox
XSOCK=/tmp/.X11-unix/X0
if [[ $@ == '--help' || $@ == "-h" ]]
then
cat $SETUP_DIR/help.txt
else
cd $SETUP_DIR
if [[ $@ == "--build" || $@ == "-b" ]]
then
docker pull debian:latest
docker build -t firefox - < $SETUP_DIR/Dockerfile
fi
xhost +localhost
docker run -v $XSOCK:$XSOCK firefox
fi
Firefox* in Docker
ff-docker [[--help|-h] [--build|-b]]
-h or --help Prints this help message
-b or --build Does a full build from scratch (necessary for first-time-use)
*Actually Iceweasel because it runs debian...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment