sambaiz / puppeteer-lambda-starter-kit

Starter Kit for running Headless-Chrome by Puppeteer on AWS Lambda.
MIT License
580 stars 82 forks source link

Failed to load libosmesa.so even with --disable-gpu flag #19

Open fractalawareness opened 6 years ago

fractalawareness commented 6 years ago

Chromium still requires osmesa even with --disable-gpu flag. It worked fine on 0.10.2 version, but fails when I use recent versions (v.1.0.0 or v1.1.1) with headless_shell binaries for that versions from this repo. I tried to use all these 'disable-gpu'-related flags with no luck:

        '--no-sandbox',
        '--disable-gpu',
        '--single-process',
        '--disable-webgl',
        '--disable-software-rasterizer',
        '--disable-accelerated-compositing',
        '--disable-force-compositing-mode',
        '--disable-accelerated-compositing',
        '--disable-accelerated-layers',
        '--blacklist-webgl',
        '--disable-accelerated-2d-canvas',
        '--disable-gpu-vsync',
        '--blacklist-accelerated-compositing',
        '--blacklist-webgl',
        '--disable-gpu-sandbox',
        '--disable-accelerated-video',
        '--disk-cache-size=0',
        '--homedir=/tmp',
        '--data-path=/tmp/data-path',
        '--disk-cache-dir=/tmp/cache-dir',
        '--user-data-dir=/tmp/user-data',

logs:

[0301/115533.993711:WARNING:resource_bundle.cc(368)] locale_file_path.empty() for locale [0301/115533.999319:WARNING:resource_bundle.cc(368)] locale_file_path.empty() for locale [0301/115534.002328:ERROR:gpu_process_transport_factory.cc(1017)] Lost UI shared context. DevTools listening on ws://127.0.0.1:43536/devtools/browser/f8530605-40nc-420a-a05b-dad9c2367629 [0301/115534.003021:ERROR:devtools_http_handler.cc(277)] Error writing DevTools active port to file Fontconfig warning: "/etc/fonts/fonts.conf", line 146: blank doesn't take any effect anymore. please remove it from your fonts.conf [0301/115534.024673:WARNING:histograms.cc(40)] Started multiple compositor clients (Browser, Renderer) in one process. Some metrics will be disabled. [0301/115534.146301:ERROR:gl_implementation.cc(292)] Failed to load /opt/lambdas/screenshot/bin/libosmesa.so: /opt/lambdas/screenshot/bin/libosmesa.so: cannot open shared object file: No such file or directory