Closed cryptcoin-junkey closed 6 years ago
EACCES errors typically mean that you do not have the permissions to create the directory/file... that is what it looks like here.
Phantom installation failed [ { [Error: EACCES: permission denied, mkdir '/usr/lib/node_modules/mocha-phantomjs/node_modules/phantomjs/lib/phantom']
This does not look to be an issue with counterwallet.
It looks the issue is caused by https://github.com/Medium/phantomjs/issues/707.
So the way to fix is two. Installng npm < 5.x or adding --unsafe-perm
to npm install mocha-phantomjs
.
Which is better?
@jdogresorg Yes. It is not Counterwallet itself. But Dockerfile in this repo.
It causes the another problem just by adding --unsafe-perm
(grunt didn't work. I don't know why).
So it should be like this.
diff --git a/Dockerfile b/Dockerfile
index 1932f1b..8c9c06d 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -77,7 +77,7 @@ COPY . /counterwallet
RUN rm -rf /counterwallet/build
WORKDIR /counterwallet
RUN git rev-parse HEAD
-RUN npm -g install npm@latest
+RUN npm -g install npm@4
RUN npm config set strict-ssl false
ENV PHANTOMJS_CDNURL="http://cnpmjs.org/downloads"
RUN npm install -g bower grunt mocha-phantomjs
@cryptcoin-junkey do you want to create a PR for this?
@unsystemizer Of course I'll create a PR if my suspect was reasonable. This issue is a tether which is the best way to fix.
I close this since this issue was fixed by 4e26454. Thanks @deweller
I tried to build the Docker image and got the error like this.