Sign inSign up

caperneoignis/chrome-headless-browser

By caperneoignis

•Updated over 5 years ago

Chrome headless browser using the latest stable version of chrome.

Image
0

10K+

caperneoignis/chrome-headless-browser repository overview

Build Status

To find the docker file go here⁠.

⁠Chrome Headless Browser

This docker image contain the Linux Dev channel Chromium (https://www.chromium.org/getting-involved/dev-channel⁠), with the required dependencies and the command line argument running headless mode provided.


⁠How to run the container:

To run the container with remote-debugging:

docker run --init -it --rm --name chrome -p=9222:9222 --cap-add=SYS_ADMIN \
  caperneoignis/chrome-headless-browser

To run the container with other options, e.g. --dump-dom:

docker run --init -it --rm --name chrome --cap-add=SYS_ADMIN \
  --entrypoint=/usr/bin/google-chrome-stable \
  caperneoignis/chrome-headless-browser \
  --headless --disable-gpu --dump-dom https://www.facebook.com

to run the container with Apache:

docker run --init -d -e APACHE_WEB_ROOT=/some/directory --name chrome -p=9222:9222 --cap-add=SYS_ADMIN \
  caperneoignis/chrome-headless-browser:latest_apache

See the following sections for alternate ways to start the container.

⁠Why cap-add=SYS_ADMIN is needed

Currently, there is a user namespace issue in OSX that generates this error:

Failed to move to new namespace: PID namespaces supported, Network namespace supported,
but failed: errno = Operation not permitted

Tag summary

Content type

Image

Digest

Size

378.9 MB

Last updated

over 5 years ago

docker pull caperneoignis/chrome-headless-browser