ChromeDriver on Alpine bind() returned an error, errno=0: Address not available (99)

Viewed 845

I'm just trying to run chromedriver in an Alpine docker container, but I keep getting this error:

Starting ChromeDriver 72.0.3626.121 on port 9515
Only local connections are allowed.
Please protect ports used by ChromeDriver and related test frameworks to prevent access by malicious code.
[1560858426.290][SEVERE]: bind() returned an error, errno=0: Address not available (99)
[1560858426.290][INFO]: listen on IPv6 failed with error ERR_ADDRESS_INVALID

The Dockerfile is simply

FROM alpine:3.9

RUN apk --no-cache --update add chromium chromium-chromedriver

EXPOSE 9515

CMD chromedriver --verbose

I'm trying to use it alongside other containers, so here is the relevant portion of the docker-compose.yml if it is helpful:

version: "3.6"

services:
  chromedriver:
    container_name: chromedriver
    build:
      context: "."
      dockerfile: "docker/test/Dockerfile.chromedriver"
    ports:
      - 9515:9515

After the error is logged, chromedriver doesn't exit and stays open, but my other containers can't seem to find the service, so I'm assuming it's not actually running and accepting connections.

Any ideas how to fix this are appreciated!

0 Answers
Related