Install Puppeteer

Puppeteer is a library to headless Chrome API. In short, most things that you can do manually in the browser can be achieved with a program using Puppeteer. By default, installing Puppeteer on a Scalingo application fails because the X11 library are not included in Scalingo base image. The error message is:

[Nest] 31 - 10/24/2019, 4:08:50 PM [ExceptionsHandler] Failed to launch chrome!
/app/node_modules/puppeteer/.local-chromium/linux-686378/chrome-linux/chrome: error while loading shared libraries: libX11-xcb.so.1: cannot open shared object file: No such file or directory

Install Puppeteer on a Scalingo Application

To install Puppeteer on a Scalingo application, you need to make use of the APT buildpack. Such a buildpack should be used as part of a multi-buildpack.

echo 'https://github.com/Scalingo/apt-buildpack' > .buildpacks
echo 'https://github.com/Scalingo/nodejs-buildpack' >> .buildpacks
git add .buildpacks
git commit --message="Add multi-buildpack"

Depending on your stack, you’ll need different system dependencies in the Aptfile at the root of your project.

  • For scalingo-22:
libgtk-3-0 libgbm-dev libnotify-dev libnss3 libxss1 libasound2 libxtst6 xauth xvfb
  • For scalingo-24:
libgtk-3-0t64 libgbm-dev libnotify-dev libnss3 libxss1 libasound2t64 libxtst6 xauth xvfb

Suggest edits

Install Puppeteer

©2026 Scalingo