Puppeteer: Installing problem on Centos 6.9

Created on 23 Aug 2017  路  3Comments  路  Source: puppeteer/puppeteer

Dear support , it seem there is a problem with installing "puppeteer" on centos
hear is System details

NPM : 5.3.0
Unmae -a
Linux server.net 2.6.32-673.26.1.lve1.4.24.el6.x86_64 #1 SMP Wed Mar 29 17:09:57 EDT 2017 x86_64 x86_64 x86_64 GNU/Linux

node -v
v8.4.0
const puppeteer = require('puppeteer');
(async() => {
  const browser = await puppeteer.launch({args: ['--no-sandbox']});
  const page = await browser.newPage();
  await page.goto('https://example.com');
  await page.screenshot({path: './example.png'});
  browser.close();
})();
root@server [~/download]# node ./test2.js
(node:656632) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): Error: Failed to connect to chrome!
(node:656632) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
root@server [~/download]#
root@server [~/download]# npm i puppeteer

> [email protected] install /root/node_modules/puppeteer
> node install.js

Downloading Chromium r494755 - 92.1 Mb [====================] 100% 0.0s
npm WARN saveError ENOENT: no such file or directory, open '/root/package.json'
npm WARN enoent ENOENT: no such file or directory, open '/root/package.json'
npm WARN root No description
npm WARN root No repository field.
npm WARN root No README data
npm WARN root No license field.

host

Most helpful comment

Adding on, I had the impression Chrome no longer works with CentOS 6.X but it'll be great if does!

https://chrome.richardlloyd.org.uk

All 3 comments

Maybe look over the existing CentOS issue ( ref #391 ). I suspect you're hitting the same missing dependency issues.

Adding on, I had the impression Chrome no longer works with CentOS 6.X but it'll be great if does!

https://chrome.richardlloyd.org.uk

Closing as a dupe of #391

Was this page helpful?
0 / 5 - 0 ratings