fb-messenger-cli icon indicating copy to clipboard operation
fb-messenger-cli copied to clipboard

Arch/Linux installation note for puppeteer EACCES error

Open jathanasiou opened this issue 7 years ago • 2 comments

Kernel: 4.18.16-arch1-1-ARCH
NPM version: 6.4.1
fb-messenger-cli version: 2.1.1 (npm latest)

As per the above, attempting to install globally in Arch/Antergos (even when using sudo) results in the following error when Puppeteer attempts to install itself.

> [email protected] install /usr/lib/node_modules/fb-messenger-cli/node_modules/puppeteer
> node install.js

ERROR: Failed to download Chromium r599821! Set "PUPPETEER_SKIP_CHROMIUM_DOWNLOAD" env variable to skip download.
{ [Error: EACCES: permission denied, mkdir '/usr/lib/node_modules/fb-messenger-cli/node_modules/puppeteer/.local-chromium']
  errno: -13,
  code: 'EACCES',
  syscall: 'mkdir',
  path:
   '/usr/lib/node_modules/fb-messenger-cli/node_modules/puppeteer/.local-chromium' }

This appears related to Puppeteer issue 375 for which the suggestion is to use the --unsafe-perm flag and appears allow for proper installation in these systems by letting the installer utilize sudo access.

The README should be updated to reflect that for Linux users.

jathanasiou avatar Nov 08 '18 17:11 jathanasiou

To clarify for others... this worked for me:

sudo npm install -g fb-messenger-cli --unsafe-perm=true

syntaxseed avatar Feb 28 '19 00:02 syntaxseed

i agree that readme should be updated

o-lenczyk avatar Dec 20 '21 11:12 o-lenczyk