Docker Community Forums

Share and learn in the Docker community.

How to append lines to Dockerfile of selenium's image

I’m not sure if it is a bug or just me being stupid but here is the case.

I want to build my image based on StandaloneChromeDebug. Following the Wiki:

  1. Pull the repo.

  2. Generate image:

$ make standalone_chrome_debug
  1. Build the Dockerfile to insure that no errors arise:
$ docker build --no-cache etc/docker-selenium/StandaloneChromeDebug/
  1. Set up my image to the docker-compose.yml like:
        container_name: selenium-hub
        build: ./etc/docker-selenium/StandaloneChromeDebug/
            - /dev/shm:/dev/shm
            - "4444:4444"
            - "5900:5900"
           - HUB_HOST=selenium-hub
           - HUB_PORT=4444

And… nothing. The container is running (no errros) but Selenium doesn’t work, container log is empty, /opt/ folder is empty.

The weird thing is: when I’m building image and use my image instead of Dockerfile it actually works. How is that possible?