addyosmani / critical

Extract & Inline Critical-path CSS in HTML pages
Apache License 2.0
10k stars 373 forks source link

Not working on Almalinux 9, without GUI. #594

Open dstorozhuk opened 4 months ago

dstorozhuk commented 4 months ago
 critical https://example.com --base public/css > public/css/critical/about-us.css --width 415 --height 1800
   Error: Failed to launch the browser process!
   /home/user/.nvm/versions/node/v18.20.2/lib/node_modules/critical/node_modules/puppeteer/.local-chromium/linux-722234/chrome-linux/chrome: error while loading shared libraries: libXss.so.1: cannot open shared object file: No such file or directory

Is that suppose to work only with linux with GUI? Does it need special setup for linux in with just a CLI interface?

bezoerb commented 4 months ago

Hey @dstorozhuk, puppeteer needs some additional dependencies. You can take a look at this Dockerfile