LoginSignup
0
0

More than 5 years have passed since last update.

Chrome Headless - 1

Posted at

Phantom.js seems dead, with a lot of holes not filled.
I have to find a replacement, so I am trying Chrome Headless now.

Install Google Chrome on Debian

Note, the following commands work only in Debian 8.
Debian 7 is not supported as a result of test.

# https://askubuntu.com/questions/79280/how-to-install-chrome-browser-properly-via-command-line
sudo apt-get install libxss1 libappindicator1 libindicator7
wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
sudo dpkg -i google-chrome*.deb  

Might show "errors", fixed by next line.

sudo apt-get install -f

Then run the dpkg again.

Try to Run

google-chrome --headless --disable-gpu --hide-scrollbars --screenshot https://sinri.cc
# [1116/113036.776865:INFO:headless_shell.cc(503)] Written to file screenshot.png.
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0