Dockerized Firefox (Firefox developer, nightly, stable)
4.2K
% docker build -t minty/firefox .
% docker build -f Dockerfile-dev -t minty/firefox:dev .
% docker build -f Dockerfile-nightly -t minty/firefox:nightly .
If you want to use your local user for downoad/profile permissions you'll need to create
~/.config/mozilla/firefox-{VERSION}and~/Downloadsahead of time.
If you leave theUSER_IDandGROUP_IDenvironment variables out of the below script therootuser will be used to start Firefox.
Place something like the below into a script somewhere, ~/bin/firefox:
#/bin/bash
version=$1
name="firefox-$version"
image="minty/firefox:$version"
if [ -z "$version" ]; then
version="release"
name="firefox"
image="minty/firefox"
fi
xhost local:root
exists=$(docker ps -a --filter name=$name | grep $name)
if [ -z "$exists" ]; then
docker run -d \
-e DISPLAY=unix$DISPLAY \
-e USER_ID=$UID \
-e GROUP_ID=$UID \
-v $HOME/Downloads:/data/Downloads \
-v $HOME/.config/mozilla/firefox-$version:/data/.firefox \
-v /dev/snd:/dev/snd --privileged \
-v /tmp/.X11-unix:/tmp/.X11-unix \
--cpuset-cpus 0 \
--memory 1024mb \
--name $name \
--net host \
$image
else
docker start -a $name
fi
Then execute it with the environment you'd like:
% firefox
% firefox dev
% firefox nightly
Content type
Image
Digest
sha256:165656f71…
Size
144.5 MB
Last updated
over 11 years ago
docker pull minty/firefox