Skip to content

Commit

Permalink
Upgrade Selenium to version 2.48.2.
Browse files Browse the repository at this point in the history
  • Loading branch information
kayabendroth committed Oct 12, 2015
1 parent 1037aa4 commit 3d34d0e
Show file tree
Hide file tree
Showing 18 changed files with 41 additions and 41 deletions.
2 changes: 1 addition & 1 deletion Base/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ RUN apt-get update -qqy \
# Selenium
#==========
RUN mkdir -p /opt/selenium \
&& wget --no-verbose http://selenium-release.storage.googleapis.com/2.48/selenium-server-standalone-2.48.1.jar -O /opt/selenium/selenium-server-standalone.jar
&& wget --no-verbose http://selenium-release.storage.googleapis.com/2.48/selenium-server-standalone-2.48.2.jar -O /opt/selenium/selenium-server-standalone.jar

#========================================
# Add normal user with passwordless sudo
Expand Down
2 changes: 1 addition & 1 deletion Hub/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM selenium/base:2.48.1
FROM selenium/base:2.48.2
MAINTAINER Selenium <[email protected]>

#========================
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
NAME := selenium
VERSION := $(or $(VERSION),$(VERSION),'2.48.1')
VERSION := $(or $(VERSION),$(VERSION),'2.48.2')
PLATFORM := $(shell uname -s)

all: hub chrome firefox chromedebug firefoxdebug standalone_chrome standalone_firefox standalone_debug_chrome standalone_debug_firefox
Expand Down
2 changes: 1 addition & 1 deletion NodeBase/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM selenium/base:2.48.1
FROM selenium/base:2.48.2
MAINTAINER Selenium <[email protected]>

ENV DEBIAN_FRONTEND noninteractive
Expand Down
2 changes: 1 addition & 1 deletion NodeChrome/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM selenium/node-base:2.48.1
FROM selenium/node-base:2.48.2
MAINTAINER Selenium <[email protected]>

USER root
Expand Down
2 changes: 1 addition & 1 deletion NodeChromeDebug/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM selenium/node-chrome:2.48.1
FROM selenium/node-chrome:2.48.2
MAINTAINER Selenium <[email protected]>

USER root
Expand Down
2 changes: 1 addition & 1 deletion NodeChromeDebug/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ If you are running Boot2Docker on Mac then you already have a [VNC client](http:
When you are prompted for the password it is __secret__. If you wish to change this then you should either change it in the `/NodeBase/Dockerfile` and build the images yourself, or you can define a docker image that derives from the posted ones which reconfigures it:

``` dockerfile
FROM selenium/node-chrome-debug:2.48.1
FROM selenium/node-chrome-debug:2.48.2

RUN x11vnc -storepasswd <your-password-here> /home/seluser/.vnc/passwd
```
Expand Down
2 changes: 1 addition & 1 deletion NodeDebug/README.template.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ If you are running Boot2Docker on Mac then you already have a [VNC client](http:
When you are prompted for the password it is __secret__. If you wish to change this then you should either change it in the `/NodeBase/Dockerfile` and build the images yourself, or you can define a docker image that derives from the posted ones which reconfigures it:

``` dockerfile
FROM selenium/##BASE##-debug:2.48.1
FROM selenium/##BASE##-debug:2.48.2

RUN x11vnc -storepasswd <your-password-here> /home/seluser/.vnc/passwd
```
Expand Down
2 changes: 1 addition & 1 deletion NodeFirefox/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM selenium/node-base:2.48.1
FROM selenium/node-base:2.48.2
MAINTAINER Selenium <[email protected]>

USER root
Expand Down
2 changes: 1 addition & 1 deletion NodeFirefoxDebug/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM selenium/node-firefox:2.48.1
FROM selenium/node-firefox:2.48.2
MAINTAINER Selenium <[email protected]>

USER root
Expand Down
2 changes: 1 addition & 1 deletion NodeFirefoxDebug/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ If you are running Boot2Docker on Mac then you already have a [VNC client](http:
When you are prompted for the password it is __secret__. If you wish to change this then you should either change it in the `/NodeBase/Dockerfile` and build the images yourself, or you can define a docker image that derives from the posted ones which reconfigures it:

``` dockerfile
FROM selenium/node-firefox-debug:2.48.1
FROM selenium/node-firefox-debug:2.48.2

RUN x11vnc -storepasswd <your-password-here> /home/seluser/.vnc/passwd
```
Expand Down
44 changes: 22 additions & 22 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Images included:
When executing docker run for an image with chrome browser please add volume mount `-v /dev/shm:/dev/shm` to use the host's shared memory.

``` bash
$ docker run -d -p 4444:4444 -v /dev/shm:/dev/shm selenium/standalone-chrome:2.48.1
$ docker run -d -p 4444:4444 -v /dev/shm:/dev/shm selenium/standalone-chrome:2.48.2
```

This is a workaround to node-chrome crash in docker container issue: https://code.google.com/p/chromium/issues/detail?id=519952
Expand All @@ -34,9 +34,9 @@ This is a workaround to node-chrome crash in docker container issue: https://cod
### Standalone Chrome and Firefox

``` bash
$ docker run -d -p 4444:4444 selenium/standalone-chrome:2.48.1
$ docker run -d -p 4444:4444 selenium/standalone-chrome:2.48.2
# OR
$ docker run -d -p 4444:4444 selenium/standalone-firefox:2.48.1
$ docker run -d -p 4444:4444 selenium/standalone-firefox:2.48.2
```

_Note: Only one standalone image can run on port_ `4444` _at a time._
Expand All @@ -46,22 +46,22 @@ To inspect visually what the browser is doing use the `standalone-chrome-debug`
### Selenium Grid Hub

``` bash
$ docker run -d -p 4444:4444 --name selenium-hub selenium/hub:2.48.1
$ docker run -d -p 4444:4444 --name selenium-hub selenium/hub:2.48.2
```

### Chrome and Firefox Grid Nodes

``` bash
$ docker run -d --link selenium-hub:hub selenium/node-chrome:2.48.1
$ docker run -d --link selenium-hub:hub selenium/node-firefox:2.48.1
$ docker run -d --link selenium-hub:hub selenium/node-chrome:2.48.2
$ docker run -d --link selenium-hub:hub selenium/node-firefox:2.48.2
```

### Java Environment Options

You can pass JAVA_OPTS environment variable to selenium java processes.

``` bash
$ docker run -d -p 4444:4444 -e JAVA_OPTS=-Xmx512m --name selenium-hub selenium/hub:2.48.1
$ docker run -d -p 4444:4444 -e JAVA_OPTS=-Xmx512m --name selenium-hub selenium/hub:2.48.2
```

## Building the images
Expand All @@ -85,10 +85,10 @@ _Note: Omitting_ `VERSION=local` _will build the images with the current version
##### Example: Spawn a container for testing in Chrome:

``` bash
$ docker run -d --name selenium-hub -p 4444:4444 selenium/hub:2.48.1
$ docker run -d --name selenium-hub -p 4444:4444 selenium/hub:2.48.2
$ CH=$(docker run --rm --name=ch \
--link selenium-hub:hub -v /e2e/uploads:/e2e/uploads \
selenium/node-chrome:2.48.1)
selenium/node-chrome:2.48.2)
```

_Note:_ `-v /e2e/uploads:/e2e/uploads` _is optional in case you are testing browser uploads on your web app you will probably need to share a directory for this._
Expand All @@ -98,10 +98,10 @@ _Note:_ `-v /e2e/uploads:/e2e/uploads` _is optional in case you are testing brow
This command line is the same as for Chrome. Remember that the Selenium running container is able to launch either Chrome or Firefox, the idea around having 2 separate containers, one for each browser is for convenience plus avoiding certain `:focus` issues your web app may encounter during end-to-end test automation.

``` bash
$ docker run -d --name selenium-hub -p 4444:4444 selenium/hub:2.48.1
$ docker run -d --name selenium-hub -p 4444:4444 selenium/hub:2.48.2
$ FF=$(docker run --rm --name=fx \
--link selenium-hub:hub -v /e2e/uploads:/e2e/uploads \
selenium/node-firefox:2.48.1)
selenium/node-firefox:2.48.2)
```

_Note: Since a Docker container is not meant to preserve state and spawning a new one takes less than 3 seconds you will likely want to remove containers after each end-to-end test with_ `--rm` _command. You need to think of your Docker containers as single processes, not as running virtual machines, in case you are familiar with [Vagrant](https://www.vagrantup.com/)._
Expand All @@ -110,15 +110,15 @@ _Note: Since a Docker container is not meant to preserve state and spawning a ne

In the event you wish to visually see what the browser is doing you will want to run the `debug` variant of node or standalone images:
``` bash
$ docker run -d -P --link selenium-hub:hub selenium/node-chrome-debug:2.48.1
$ docker run -d -P --link selenium-hub:hub selenium/node-firefox-debug:2.48.1
$ docker run -d -P --link selenium-hub:hub selenium/node-chrome-debug:2.48.2
$ docker run -d -P --link selenium-hub:hub selenium/node-firefox-debug:2.48.2
```

And for standalone:
``` bash
$ docker run -d -p 4444:4444 selenium/standalone-chrome-debug:2.48.1
$ docker run -d -p 4444:4444 selenium/standalone-chrome-debug:2.48.2
# OR
$ docker run -d -p 4444:4444 selenium/standalone-firefox-debug:2.48.1
$ docker run -d -p 4444:4444 selenium/standalone-firefox-debug:2.48.2
```

You can acquire the port that the VNC server is exposed to by running:
Expand All @@ -136,8 +136,8 @@ If you are running [Boot2Docker](https://docs.docker.com/installation/mac/) on O

When you are prompted for the password it is `secret`. If you wish to change this then you should either change it in the `/NodeBase/Dockerfile` and build the images yourself, or you can define a Docker image that derives from the posted ones which reconfigures it:
``` dockerfile
#FROM selenium/node-chrome-debug:2.48.1
#FROM selenium/node-firefox-debug:2.48.1
#FROM selenium/node-chrome-debug:2.48.2
#FROM selenium/node-firefox-debug:2.48.2
#Choose the FROM statement that works for you.

RUN x11vnc -storepasswd <your-password-here> /home/seluser/.vnc/passwd
Expand All @@ -149,11 +149,11 @@ RUN x11vnc -storepasswd <your-password-here> /home/seluser/.vnc/passwd
$ docker images
#=>
REPOSITORY TAG IMAGE ID CREATED VIRTUAL SIZE
selenium/node-firefox 2.48.1 69f762d0d79e 29 minutes ago 552.1 MB
selenium/node-chrome 2.48.1 9dd73160660b 30 minutes ago 723.6 MB
selenium/node-base 2.48.1 1b7a0b7024b1 32 minutes ago 426.1 MB
selenium/hub 2.48.1 2570bbb98229 33 minutes ago 394.4 MB
selenium/base 2.48.1 33478d455dab 33 minutes ago 362.6 MB
selenium/node-firefox 2.48.2 69f762d0d79e 29 minutes ago 552.1 MB
selenium/node-chrome 2.48.2 9dd73160660b 30 minutes ago 723.6 MB
selenium/node-base 2.48.2 1b7a0b7024b1 32 minutes ago 426.1 MB
selenium/hub 2.48.2 2570bbb98229 33 minutes ago 394.4 MB
selenium/base 2.48.2 33478d455dab 33 minutes ago 362.6 MB
ubuntu 15.04 013f3d01d247 6 days ago 131.4 MB
```

Expand Down
2 changes: 1 addition & 1 deletion StandaloneChrome/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM selenium/node-chrome:2.48.1
FROM selenium/node-chrome:2.48.2
MAINTAINER Selenium <[email protected]>

USER root
Expand Down
2 changes: 1 addition & 1 deletion StandaloneDebugChrome/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM selenium/standalone-chrome:2.48.1
FROM selenium/standalone-chrome:2.48.2
MAINTAINER Selenium <[email protected]>

USER root
Expand Down
2 changes: 1 addition & 1 deletion StandaloneDebugFirefox/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM selenium/standalone-firefox:2.48.1
FROM selenium/standalone-firefox:2.48.2
MAINTAINER Selenium <[email protected]>

USER root
Expand Down
2 changes: 1 addition & 1 deletion StandaloneFirefox/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM selenium/node-firefox:2.48.1
FROM selenium/node-firefox:2.48.2
MAINTAINER Selenium <[email protected]>

USER root
Expand Down
2 changes: 1 addition & 1 deletion sa-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ function test_standalone {
BROWSER=$1
echo Starting Selenium standalone-$BROWSER$DEBUG container

SA=$(docker run -d selenium/standalone-$BROWSER$DEBUG:2.48.1)
SA=$(docker run -d selenium/standalone-$BROWSER$DEBUG:2.48.2)
SA_NAME=$(docker inspect -f '{{ .Name }}' $SA | sed s:/::)
TEST_CMD="node smoke-$BROWSER.js"

Expand Down
6 changes: 3 additions & 3 deletions test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,16 @@ echo Building test container image
docker build -t selenium/test:local ./Test

echo 'Starting Selenium Hub Container...'
HUB=$(docker run -d selenium/hub:2.48.1)
HUB=$(docker run -d selenium/hub:2.48.2)
HUB_NAME=$(docker inspect -f '{{ .Name }}' $HUB | sed s:/::)
echo 'Waiting for Hub to come online...'
docker logs -f $HUB &
sleep 2

echo 'Starting Selenium Chrome node...'
NODE_CHROME=$(docker run -d --link $HUB_NAME:hub selenium/node-chrome$DEBUG:2.48.1)
NODE_CHROME=$(docker run -d --link $HUB_NAME:hub selenium/node-chrome$DEBUG:2.48.2)
echo 'Starting Selenium Firefox node...'
NODE_FIREFOX=$(docker run -d --link $HUB_NAME:hub selenium/node-firefox$DEBUG:2.48.1)
NODE_FIREFOX=$(docker run -d --link $HUB_NAME:hub selenium/node-firefox$DEBUG:2.48.2)
docker logs -f $NODE_CHROME &
docker logs -f $NODE_FIREFOX &
echo 'Waiting for nodes to register and come online...'
Expand Down

0 comments on commit 3d34d0e

Please sign in to comment.