-
Notifications
You must be signed in to change notification settings - Fork 436
Installation fails with npm 5 #707
Comments
phantomjs-prebuilt can not be installed globally with npm5 (see Medium/phantomjs#707)
phantomjs-prebuilt can not be installed globally with npm5 (see Medium/phantomjs#707)
using nodejs 7.x and npm 4 instead |
I have the same issue even without sudo. |
This is still happening with npm version 5.0.4 |
That's a bad news. I can't use nodeJs8 just because I must run CI in phantomJs browser. |
+1 |
3 similar comments
+1 |
+1 |
+1 |
++ |
+1 |
1 similar comment
+1 |
This may or may not help some of you, but using |
I got it to work by doing this |
Still happen with |
Looks like the copy of the uncompressed directory is moved using fs.move which is from fs-extra which uses
EACCES meaning according to the manpage:
Which is expected as this section is ran as the I'm not a npm guy enough to tell how it should work though. see: npm/npm#17906 |
@JulienPalard did you try |
@happilymarrieddad I'm using ansible, so I don't think I can pass the (undocumented?) --unsafe-perm flag :( |
@JulienPalard This worked for me in ansible
|
@bryanleetc Yes |
OMG this issue costed me 3 hours of googling. Solved by --unsafe-perm but not really easy to understand... |
Bypasses phantomjs privilege errors: Medium/phantomjs#707
If someone uses Elastic Beanstalk (Node 8), adding this .ebextensions file let it work again ;) (also uses the --unsafe-perm "hack")
|
Note for everyone running into this: both Chrome and Firefox now support headless mode. With this PhantomJS has come to the end of its days, because there is no need for it anymore. You can now use Chrome, Chromium or Firefox for any scenario where you would otherwise use PhantomJS. |
Still happening in 2018 under docker container, node 8 and npm 5.6.0. Is this not a phantomjs issue? Is there an official answer of what to do? Is this not important? I was able to install with --unsafe-perm though. |
sudo apt install phantomjs This worked well for me on Ubuntu 16.04 |
+1 in 2018, trying to install phantomjs in docker container... I guess this will never be fixed... |
Still occurring, node 8.11.1/ npm 5.8.0 or 5.6.0. Tested on Ubuntu 17.10 and 18.04. |
This worked for me:
|
found the solution. https://smohan.net/blog/me7esu |
a solution for phantomjs 1.9.8 version. |
@simllll your 'crazy' configuration file didnt work form me. Trying on 64bit Amazon Linux/4.5.2 node 8.11.3. Installation was successful with selecting node 7.10.1 on the sami AMI version but with version 8 it fails |
@Coffy probably the script is outdated in the meantime, I really suggest you to use puppeteer though! |
For me, I only had to change my Docker hub image from:
to
|
Thank you so much. I had been trying to solve that with npm and didn't work out. But with your suggestion, it works well. |
Still happening - this time on Mac and
|
I have same issue using docker |
As a note, see ariya/phantomjs#15344 where phantomjs itself has suspended development and been archived, though it seems more likely this is npm-related. |
wget https://npm.taobao.org/mirrors/phantomjs/phantomjs-2.1.1-linux-x86_64.tar.bz2
tar -jxvf phantomjs-2.1.1-linux-x86_64.tar.bz2
vim /etc/profile
export PATH=$PATH:/usr/local/phantomjs-2.1.1-linux-x86_64/bin
source /etc/profile
# in your project
rm -rf ./node_modules
npm install --unsafe-perm
npm run build
|
Installation of phantomjs-prebuilt started failing after upgrading to npm from 3.x to 5.0.1
I am using:
sudo npm install -g phantomjs-prebuilt
, with default NodeSource installation,sudo
is needed for installing global packages.The text was updated successfully, but these errors were encountered: