Skip to content

Commit

Permalink
Add a different version of Firefox and ability to switch to it using …
Browse files Browse the repository at this point in the history
…an env variable
  • Loading branch information
erdi committed May 22, 2017
1 parent 06894e1 commit 219b5d0
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 3 deletions.
13 changes: 10 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ RUN apt-get update && apt-get install -y \
xvfb \
curl \
bzip2 \
libgtk-3-dev \
libgtk-3-dev \
wget

RUN wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add -
Expand All @@ -16,10 +16,17 @@ RUN sh -c 'echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable
RUN apt-get update && apt-get install -y \
google-chrome-stable

RUN mkdir -p /opt/firefox/46.0.1
RUN curl -SL https://ftp.mozilla.org/pub/firefox/releases/46.0.1/linux-x86_64/en-US/firefox-46.0.1.tar.bz2 \
| tar -xjC /opt
| tar -xjC /opt/firefox/46.0.1

RUN ln -s /opt/firefox/firefox /usr/bin/firefox
RUN mkdir -p /opt/firefox/53.0.3
RUN curl -SL https://ftp.mozilla.org/pub/firefox/releases/53.0.3/linux-x86_64/en-US/firefox-53.0.3.tar.bz2 \
| tar -xjC /opt/firefox/53.0.3

COPY firefox.sh /usr/bin/firefox

RUN chmod +x /usr/bin/firefox

COPY google-chrome.sh /usr/bin/google-chrome

Expand Down
5 changes: 5 additions & 0 deletions firefox.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/bin/bash

: ${FIREFOX_VERSION:=46.0.1}

/opt/firefox/$FIREFOX_VERSION/firefox/firefox "$@"

0 comments on commit 219b5d0

Please sign in to comment.