Open AndyAyrey opened 3 years ago
Any help on this one ?
@Carlosf96 I've worked around it by using a containerized Github Action to build PDFs as part of the Gatsby Cloud deployment sequence. It's not the most elegant but it works ok: https://github.com/Zygar/pagedjs-cli-github-action
I use this docker image for CI: satantime/puppeteer-node:16
but still has other problem:
error "gatsby-plugin-pdf" threw an error while running the onPostBuild lifecycle:
[96](https://git.corp.acflow.com/app-internal/protocol-document/-/jobs/2896#L96)Failed to launch the browser process!
[97](https://git.corp.acflow.com/app-internal/protocol-document/-/jobs/2896#L97)[0908/035510.886998:ERROR:zygote_host_impl_linux.cc(90)] Running as root without --no-sandbox is not supported. See https://crbug.com/638180.
[98](https://git.corp.acflow.com/app-internal/protocol-document/-/jobs/2896#L98)TROUBLESHOOTING: https://github.com/puppeteer/puppeteer/blob/main/docs/troubleshooting.md
The Puppeteer dependency introduces some sensitivities to the deployment environment. Attempting to build on Gatsby Cloud or Digital Ocean generates:
Presumption is that these environments are containerised and lack the modules that Puppeteer depends on
Do you see any way around this, or is the best solution just to roll-your-own CI solution with a VPS?