Skip to content

Commit 95d3fcc

Browse files
committed
Add support for Firefox 46.0.1 and 47.0.1
Make Firefox 47.0.1 the default version
1 parent c7d06ec commit 95d3fcc

File tree

9 files changed

+48
-19
lines changed

9 files changed

+48
-19
lines changed

NodeBase/entry_point.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,10 @@ if [ ! -z "$REMOTE_HOST" ]; then
2525
REMOTE_HOST_PARAM="-remoteHost $REMOTE_HOST"
2626
fi
2727

28+
if [ ! -z "$FIREFOX_VERSION" ]; then
29+
sudo ln -fs /opt/firefox/${FIREFOX_VERSION}/firefox /usr/bin/firefox
30+
fi
31+
2832
if [ ! -z "$SE_OPTS" ]; then
2933
echo "appending selenium options: ${SE_OPTS}"
3034
fi

NodeChromeDebug/entry_point.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,10 @@ if [ ! -z "$REMOTE_HOST" ]; then
2525
REMOTE_HOST_PARAM="-remoteHost $REMOTE_HOST"
2626
fi
2727

28+
if [ ! -z "$FIREFOX_VERSION" ]; then
29+
sudo ln -fs /opt/firefox/${FIREFOX_VERSION}/firefox /usr/bin/firefox
30+
fi
31+
2832
if [ ! -z "$SE_OPTS" ]; then
2933
echo "appending selenium options: ${SE_OPTS}"
3034
fi

NodeFirefox/Dockerfile

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6,17 +6,19 @@ USER root
66
#=========
77
# Firefox
88
#=========
9-
ENV FIREFOX_VERSION 45.0.2
109
RUN apt-get update -qqy \
1110
&& apt-get -qqy --no-install-recommends install firefox \
1211
&& rm -rf /var/lib/apt/lists/* \
13-
&& wget --no-verbose -O /tmp/firefox.tar.bz2 https://download-installer.cdn.mozilla.net/pub/firefox/releases/$FIREFOX_VERSION/linux-x86_64/en-US/firefox-$FIREFOX_VERSION.tar.bz2 \
14-
&& apt-get -y purge firefox \
15-
&& rm -rf /opt/firefox \
16-
&& tar -C /opt -xjf /tmp/firefox.tar.bz2 \
17-
&& rm /tmp/firefox.tar.bz2 \
18-
&& mv /opt/firefox /opt/firefox-$FIREFOX_VERSION \
19-
&& ln -fs /opt/firefox-$FIREFOX_VERSION/firefox /usr/bin/firefox
12+
&& apt-get -y purge firefox
13+
RUN wget --no-verbose -O /tmp/firefox-45.0.2.tar.bz2 https://download-installer.cdn.mozilla.net/pub/firefox/releases/45.0.2/linux-x86_64/en-US/firefox-45.0.2.tar.bz2 \
14+
&& wget --no-verbose -O /tmp/firefox-46.0.1.tar.bz2 https://download-installer.cdn.mozilla.net/pub/firefox/releases/46.0.1/linux-x86_64/en-US/firefox-46.0.1.tar.bz2 \
15+
&& wget --no-verbose -O /tmp/firefox-47.0.1.tar.bz2 https://download-installer.cdn.mozilla.net/pub/firefox/releases/47.0.1/linux-x86_64/en-US/firefox-47.0.1.tar.bz2
16+
RUN mkdir -p /opt/firefox/45.0.2 && tar -C /opt/firefox/45.0.2 --strip-components 1 -xjf /tmp/firefox-45.0.2.tar.bz2 \
17+
&& mkdir -p /opt/firefox/46.0.1 && tar -C /opt/firefox/46.0.1 --strip-components 1 -xjf /tmp/firefox-46.0.1.tar.bz2 \
18+
&& mkdir -p /opt/firefox/47.0.1 && tar -C /opt/firefox/47.0.1 --strip-components 1 -xjf /tmp/firefox-47.0.1.tar.bz2 \
19+
&& rm /tmp/firefox-*.tar.bz2
20+
ENV FIREFOX_VERSION 47.0.1
21+
RUN ln -fs /opt/firefox/${FIREFOX_VERSION}/firefox /usr/bin/firefox
2022

2123
#========================
2224
# Selenium Configuration

NodeFirefox/Dockerfile.txt

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5,17 +5,19 @@ USER root
55
#=========
66
# Firefox
77
#=========
8-
ENV FIREFOX_VERSION 45.0.2
98
RUN apt-get update -qqy \
109
&& apt-get -qqy --no-install-recommends install firefox \
1110
&& rm -rf /var/lib/apt/lists/* \
12-
&& wget --no-verbose -O /tmp/firefox.tar.bz2 https://download-installer.cdn.mozilla.net/pub/firefox/releases/$FIREFOX_VERSION/linux-x86_64/en-US/firefox-$FIREFOX_VERSION.tar.bz2 \
13-
&& apt-get -y purge firefox \
14-
&& rm -rf /opt/firefox \
15-
&& tar -C /opt -xjf /tmp/firefox.tar.bz2 \
16-
&& rm /tmp/firefox.tar.bz2 \
17-
&& mv /opt/firefox /opt/firefox-$FIREFOX_VERSION \
18-
&& ln -fs /opt/firefox-$FIREFOX_VERSION/firefox /usr/bin/firefox
11+
&& apt-get -y purge firefox
12+
RUN wget --no-verbose -O /tmp/firefox-45.0.2.tar.bz2 https://download-installer.cdn.mozilla.net/pub/firefox/releases/45.0.2/linux-x86_64/en-US/firefox-45.0.2.tar.bz2 \
13+
&& wget --no-verbose -O /tmp/firefox-46.0.1.tar.bz2 https://download-installer.cdn.mozilla.net/pub/firefox/releases/46.0.1/linux-x86_64/en-US/firefox-46.0.1.tar.bz2 \
14+
&& wget --no-verbose -O /tmp/firefox-47.0.1.tar.bz2 https://download-installer.cdn.mozilla.net/pub/firefox/releases/47.0.1/linux-x86_64/en-US/firefox-47.0.1.tar.bz2
15+
RUN mkdir -p /opt/firefox/45.0.2 && tar -C /opt/firefox/45.0.2 --strip-components 1 -xjf /tmp/firefox-45.0.2.tar.bz2 \
16+
&& mkdir -p /opt/firefox/46.0.1 && tar -C /opt/firefox/46.0.1 --strip-components 1 -xjf /tmp/firefox-46.0.1.tar.bz2 \
17+
&& mkdir -p /opt/firefox/47.0.1 && tar -C /opt/firefox/47.0.1 --strip-components 1 -xjf /tmp/firefox-47.0.1.tar.bz2 \
18+
&& rm /tmp/firefox-*.tar.bz2
19+
ENV FIREFOX_VERSION 47.0.1
20+
RUN ln -fs /opt/firefox/${FIREFOX_VERSION}/firefox /usr/bin/firefox
1921

2022
#========================
2123
# Selenium Configuration

NodeFirefoxDebug/entry_point.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,10 @@ if [ ! -z "$REMOTE_HOST" ]; then
2525
REMOTE_HOST_PARAM="-remoteHost $REMOTE_HOST"
2626
fi
2727

28+
if [ ! -z "$FIREFOX_VERSION" ]; then
29+
sudo ln -fs /opt/firefox/${FIREFOX_VERSION}/firefox /usr/bin/firefox
30+
fi
31+
2832
if [ ! -z "$SE_OPTS" ]; then
2933
echo "appending selenium options: ${SE_OPTS}"
3034
fi

README.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -62,12 +62,13 @@ By default the latest stable versions will be used, however you can override
6262
these using the following environment variables:
6363

6464
- `SELENIUM_VERSION` - version of the Selenium server
65+
- `FIREFOX_VERSION` - version of Firefox (only applies to Firefox images)
6566

66-
For example, the following will start a standalone Firefox server using
67-
Selenium 2.53.0:
67+
For example, the following will start a standalone server using Selenium 2.53.0
68+
and Firefox 45.0.2:
6869

6970
```bash
70-
$ docker run -d -p 4444:4444 -e SELENIUM_VERSION=2.53.0 selenium/standalone-firefox:2.53.1
71+
$ docker run -d -p 4444:4444 -e SELENIUM_VERSION=2.53.0 -e FIREFOX_VERSION=45.0.2 selenium/standalone-firefox:2.53.1
7172
```
7273

7374
### JAVA_OPTS Java Environment Options

Standalone/entry_point.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@ function shutdown {
99
wait $NODE_PID
1010
}
1111

12+
if [ ! -z "$FIREFOX_VERSION" ]; then
13+
sudo ln -fs /opt/firefox/${FIREFOX_VERSION}/firefox /usr/bin/firefox
14+
fi
15+
1216
if [ ! -z "$SE_OPTS" ]; then
1317
echo "appending selenium options: ${SE_OPTS}"
1418
fi

StandaloneChrome/entry_point.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@ function shutdown {
99
wait $NODE_PID
1010
}
1111

12+
if [ ! -z "$FIREFOX_VERSION" ]; then
13+
sudo ln -fs /opt/firefox/${FIREFOX_VERSION}/firefox /usr/bin/firefox
14+
fi
15+
1216
if [ ! -z "$SE_OPTS" ]; then
1317
echo "appending selenium options: ${SE_OPTS}"
1418
fi

StandaloneFirefox/entry_point.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@ function shutdown {
99
wait $NODE_PID
1010
}
1111

12+
if [ ! -z "$FIREFOX_VERSION" ]; then
13+
sudo ln -fs /opt/firefox/${FIREFOX_VERSION}/firefox /usr/bin/firefox
14+
fi
15+
1216
if [ ! -z "$SE_OPTS" ]; then
1317
echo "appending selenium options: ${SE_OPTS}"
1418
fi

0 commit comments

Comments
 (0)