Running Puppeteer with Headless Chrome: Enabling the --no-sandbox Option

Deploying a Puppeteer app in Docker triggers sandbox permission issues. How can I supply the --no-sandbox flag via the startup command or Dockerfile?

FROM debian:latest
RUN apt-get update && apt-get install -y chromium
CMD ["chromium", "--headless", "--no-sandbox"]

docker run -p 8080:8080 project_image

hey, try passing --no-sandbox in your puppeteer.launch args instead of relying on the CMD in docker. i had a similar issue and switching to config resolved it for me. check that your chromium version supports it