Use bullseye (stable) instead of sid (unstable) as base-image
Make it possible to change this at buildtime with the buildarg DEBVERSION
Take firefox from bionic (newest LTS) instead of xenial (older LTS)
Make it possible to change this at buildtime with the buildarg UBUVERSION
Use UTF-8 as default LANG
Run it as user user with homedir /home/user
Make it possible to change this at buildtime with the buildargs USER and HOME
Add example usage in such a way that DIR=firefox make run work
Warning: Users that use firefox both in a container and in the usual way may lose there firefox profile because of -v $HOME/.mozilla:/home/user/.mozilla when the firefox versions are not equal.
So this gives us three options:
I could leave it like this and call it 'wanted behavior' (perfect for users that only use firefox in a container)
I could remove it which will cause the user to lose the container profile every time he restarts it. (perfect for users that only rarely use firefox in a container)
I could change $HOME/.mozilla to another dir, no profile will be lost but it will only work if the user has this dir. (perfect if the user can somehow be forced to make sure that new dir exists)
DEBVERSION
UBUVERSION
LANG
user
with homedir/home/user
USER
andHOME
DIR=firefox make run
workWarning: Users that use firefox both in a container and in the usual way may lose there firefox profile because of
-v $HOME/.mozilla:/home/user/.mozilla
when the firefox versions are not equal. So this gives us three options:$HOME/.mozilla
to another dir, no profile will be lost but it will only work if the user has this dir. (perfect if the user can somehow be forced to make sure that new dir exists)Opinions please... (My favorite is the 1st one)