pwa-asset-generator icon indicating copy to clipboard operation
pwa-asset-generator copied to clipboard

`--no-sandbox` doesn't work, but `-n` or `--noSandbox` does

Open abeluck opened this issue 2 years ago • 3 comments

Describe the bug The help says:

      -n --no-sandbox             Disable sandbox on bundled Chromium on Linux platforms - not recommended  [default: false]

However passing --no-sandbox doesn't work. By reading the code I saw that --noSandbox is referenced, and this flag does indeed work.

To Reproduce Steps to reproduce the behavior:

  1. Execute cli command sudo pwa-asset-generator logo.html --no-sandbox
  2. See error
...
[0811/111857.270844:ERROR:zygote_host_impl_linux.cc(90)] Running as root without --no-sandbox is not supported. See https://crbug.com/638180.
TROUBLESHOOTING: https://github.com/puppeteer/puppeteer/blob/main/docs/troubleshooting.md
 😭

Expected behavior The documented command line flag should work.

System (please complete the following information):

  • OS: linux
  • node version: v18.16.0
  • npm version: 9.5.1
  • cli version: 6.3.1

abeluck avatar Aug 11 '23 11:08 abeluck

I can reproduce this, the problem is that --no-sandbox is parsed as --sandbox false, which is a different flag name.

atjn avatar Aug 24 '24 22:08 atjn

no-sandbox arg can be set with an env var with v7.0.0.

PAG_USE_NO_SANDBOX=1 pwa-asset-generator ...

onderceylan avatar Mar 21 '25 23:03 onderceylan

This issue is not resolved, the documentation for v7.0.0 still says that you can use the --no-sandbox flag, but that does not work.

atjn avatar Mar 27 '25 08:03 atjn