timarney / react-app-rewired

Override create-react-app webpack configs without ejecting
MIT License
9.76k stars 425 forks source link

Error Running react-app-rewired build && compress-cra on Amazon Linux #643

Open faridanthony opened 1 year ago

faridanthony commented 1 year ago
$ yarn build
yarn run v1.22.18
$ react-app-rewired build && compress-cra
Creating an optimized production build...
/var/www/project-root/node_modules/react-scripts/scripts/build.js:19
  throw err;
  ^

Error: Failed to launch chrome!
/var/www/project-root/node_modules/puppeteer/.local-chromium/linux-637110/chrome-linux/chrome: error while loading shared libraries: libXss.so.1: cannot open shared object file: No such file or directory

TROUBLESHOOTING: https://github.com/GoogleChrome/puppeteer/blob/master/docs/troubleshooting.md

    at onClose (/var/www/project-root/node_modules/puppeteer/lib/Launcher.js:342:14)
    at Interface.<anonymous> (/var/www/project-rooti/node_modules/puppeteer/lib/Launcher.js:331:50)
    at Interface.emit (node:events:539:35)
    at Interface.close (node:readline:586:8)
    at Socket.onend (node:readline:277:10)
    at Socket.emit (node:events:539:35)
    at endReadableNT (node:internal/streams/readable:1345:12)
    at processTicksAndRejections (node:internal/process/task_queues:83:21)
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.