title: How do I deploy Puppeteer onto Heroku?
body: <p>For whatever reason, I am unable to deploy puppeteer correctly on to heroku. It builds, but when I run it, I get the application error page. When I check the logs, I get:</p>
  <pre><code>2020-09-09T22:44:38.942371+00:00 app[web.1]: (node:4) UnhandledPromiseRejectionWarning: Error: Failed to launch the browser process!
  2020-09-09T22:44:38.942389+00:00 app[web.1]: [0909/224438.137880:FATAL:zygote_host_impl_linux.cc(117)] No usable sandbox! Update your kernel or see https://chromium.googlesource.com/chromium/src/+/master/docs/linux/suid_sandbox_development.md for more information on developing with the SUID sandbox. If you want to live dangerously and need an immediate workaround, you can try using --no-sandbox.
  </code></pre>
  <p>Which is telling me 1) the browser doesn't launch for whatever reason, and 2) that there's no sandbox.</p>
  <p>The basic code I'm using is this:</p>
  <pre><code>const browser = await puppeteer.launch(
  {
      headless: false,
      args: [&quot;no-sandbox&quot;, &quot;--disable-setuid-sandbox&quot;],
  });
  </code></pre>
  <p>As you can see, I've already tried the no-sandbox option that I've seen on SO. I've tried setting headless to true and false, no difference.</p>
  <p>Here is my webpacks I have on Heroku.</p>
  <pre><code>https://github.com/jontewks/puppeteer-heroku-buildpack
  https://github.com/heroku/heroku-buildpack-google-chrome
  heroku/nodejs
  </code></pre>
  <p>Do I need more? Do I need one specifically for Chromium?</p>