

maxrodrigo / install-chrome-headless.sh Last active last month Star 12 Fork 1 Code Revisions 3 Stars 12 Forks 1 Embed Download ZIP Puppeteer/Chrome Headless on EC2 Amazon Linux AMI Raw install-chrome-headless. Puppeteer is a headless Node library that provides a high level API for controlling Chromium or Chrome over the DevTools protocol. Unofficial Python port of puppeteer JavaScript (headless) chrome/chromium browser automation library. The same JS that executes in headless Chrome on the server runs again when the user's browser loads the page on the frontend.

Here's my setup: const puppeteer = require('puppeteer-extra') Ĭonst StealthPlugin = require('puppeteer-extra-plugin-stealth') Ĭonst randomUseragent = require('random-useragent') Ĭonst USER_AGENT = 'Mozilla/5.0 (Macintosh Intel Mac OS X 10_14_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/.75 Safari/537. Puppeteer/Chrome Headless on EC2 Amazon Linux AMI GitHub Instantly share code, notes, and snippets. Our Express app takes a request, uses Puppeteer to load the page into headless, and serves the result as a response.

Im using puppeteer-extra-plugin-stealth, random-useragent and viewport randomization but nothing seems to work.Ĭould it be that puppeteer and/or chrome is adding extra stuff when running locally vs on Heroku? I understand that puppeteer comes with javascript enabled by default and for what I've read it looks like it has nothing to do with that. My setup works when I try it locally on my machine, but when trying it mounted on Heroku I get something like this: Im trying to access a site with headless chrome using puppeteer on Heroku.
