Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed at nodent-runtime install script #191

Closed
JumpyWizard404 opened this issue Mar 3, 2020 · 10 comments
Closed

Failed at nodent-runtime install script #191

JumpyWizard404 opened this issue Mar 3, 2020 · 10 comments
Labels
question Further information is requested

Comments

@JumpyWizard404
Copy link

Hello Everyone i have been triying to set up praeco using manuall install procedure. Ive managed to get to the step npm install in the praeco directory but the following issue happens:

Error: EACCES: permission denied, open '/etc/praeco/node_modules/nodent-runtime/dist/index.js'
at Object.openSync (fs.js:461:3)
at Object.writeFileSync (fs.js:1302:35)
at Object. (/etc/praeco/node_modules/nodent-runtime/build.js:5:4)
at Module._compile (internal/modules/cjs/loader.js:1151:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1171:10)
at Module.load (internal/modules/cjs/loader.js:1000:32)
at Function.Module._load (internal/modules/cjs/loader.js:899:14)
at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:71:12)
at internal/main/run_main_module.js:17:47 {
errno: -13,
syscall: 'open',
code: 'EACCES',
path: '/etc/praeco/node_modules/nodent-runtime/dist/index.js'
}
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules/vue-native-websocket/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! nodent-runtime@3.2.1 install: node build.js
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the nodent-runtime@3.2.1 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2020-03-03T14_30_37_982Z-debug.log
When i look at the directory the dir nodent-runtime does not exit. can anyone point me in the right direction? Any help woould be appreciated

@JumpyWizard404
Copy link
Author

As an additional note im setting this up on CentOS 7

@daichi703n
Copy link

daichi703n commented Mar 3, 2020

Hi, @JumpyWizard404
How did you setup your server?

I tested clean install on CentOS:7 DockerImage, and it succeeded.

$ docker run -it --name test-praeco centos:7 bash
[root@602fe5e5d2f9 praeco]# cat /etc/redhat-release
CentOS Linux release 7.6.1810 (Core)
[root@602fe5e5d2f9 /]# cd /etc/
[root@602fe5e5d2f9 etc]# yum install git -y
[root@602fe5e5d2f9 etc]# curl -sL https://rpm.nodesource.com/setup_12.x | bash -
[root@602fe5e5d2f9 etc]# yum install nodejs -y
[root@602fe5e5d2f9 etc]# git clone https://github.com/ServerCentral/praeco
[root@602fe5e5d2f9 etc]# cd praeco/
[root@602fe5e5d2f9 praeco]# npm install

> nodent-runtime@3.2.1 install /praeco/node_modules/nodent-runtime
> node build.js

## Built /praeco/node_modules/nodent-runtime/dist/index.js

> yorkie@2.0.0 install /praeco/node_modules/yorkie
> node bin/install.js

setting up Git hooks
done


> husky@1.3.1 install /praeco/node_modules/husky
> node husky install

husky > setting up git hooks
husky > done

> node-sass@4.12.0 install /praeco/node_modules/node-sass
> node scripts/install.js

Downloading binary from https://github.com/sass/node-sass/releases/download/v4.12.0/linux-x64-72_binding.node
Download complete .] - :
Binary saved to /praeco/node_modules/node-sass/vendor/linux-x64-72/binding.node
Caching binary to /root/.npm/node-sass/4.12.0/linux-x64-72_binding.node

> uglifyjs-webpack-plugin@0.4.6 postinstall /praeco/node_modules/vue-native-websocket/node_modules/uglifyjs-webpack-plugin
> node lib/post_install.js


> node-sass@4.12.0 postinstall /praeco/node_modules/node-sass
> node scripts/build.js

Binary found at /praeco/node_modules/node-sass/vendor/linux-x64-72/binding.node
Testing binary
Binary is fine
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules/vue-native-websocket/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})

added 2858 packages from 2290 contributors and audited 19895 packages in 127.093s
found 600 vulnerabilities (5 low, 16 moderate, 578 high, 1 critical)
  run `npm audit fix` to fix them, or `npm audit` for details

[root@602fe5e5d2f9 praeco]# npm run serve

> praeco@1.0.1 serve /praeco
> vue-cli-service serve

 INFO  Starting development server...
 11% building modules 14/20 modules 6 active ...eco/node_modules/html-entities/index.jsBrowserslist: caniuse-lite is outdated. Please run next command `npm update caniuse-lite browserslist`
 98% after emitting SizeLimitsPlugin

 DONE  Compiled successfully in 46394ms                                                                                           3:56:23 PM


  App running at:
  - Local:   http://localhost:8080/

  It seems you are running Vue CLI inside a container.
  Access the dev server via http://localhost:<your container's external mapped port>/

  Note that the development build is not optimized.
  To create a production build, run npm run build.

^C
[root@602fe5e5d2f9 praeco]#

@JumpyWizard404
Copy link
Author

JumpyWizard404 commented Mar 3, 2020

i followed the manually installation steps from https://github.com/ServerCentral/praeco from the bottom of the page. I am avoiding in using docker in setting this up as our production private cloud environment does not use docker.

@daichi703n
Copy link

I see.
Do your node.js and mpm work properly? Please check with node -v, npm -v.

Did you run git clone and npm install with root? (It’s OK)

Error: EACCES: permission denied, open '/etc/praeco/node_modules/nodent-runtime/dist/index.js'

I’m wondering why permission denied is happening.

@JumpyWizard404
Copy link
Author

ive checked both node -V 13.9.0 npm -v 6.13.7 i also installed and set elastalert and elastalert-server by using python and pythonpip 3 instead of 2 and yes i ran everything as root.

@daichi703n
Copy link

@johnsusek It seems to be problem with dependency packages.
Did you test Praeco with nodejs v13? (v13 is not LTS, I think v13 support is not required, but it's good to supporting any nodejs versions.)

@JumpyWizard404
I also failed installation with nodejs v13.

[root@f49437a6522d praeco]# node -v
v13.9.0
[root@f49437a6522d praeco]# npm -v
6.13.7

But, error occured by other reason? In any case, it seems to be problem with dependency packages.

[root@f49437a6522d /]# cd etc/
[root@f49437a6522d etc]# curl -sL https://rpm.nodesource.com/setup_13.x | bash -
[root@f49437a6522d etc]# yum install git nodejs -y
========================================================================================================================
 Package                            Arch               Version                             Repository              Size
========================================================================================================================
Installing:
 git                                x86_64             1.8.3.1-21.el7_7                    updates                4.4 M
 nodejs                             x86_64             2:13.9.0-1nodesource                nodesource              32 M
...
Complete!
[root@f49437a6522d etc]# git clone https://github.com/ServerCentral/praeco
[root@f49437a6522d etc]# cd praeco
[root@f49437a6522d praeco]# npm install

> nodent-runtime@3.2.1 install /etc/praeco/node_modules/nodent-runtime
> node build.js

## Built /etc/praeco/node_modules/nodent-runtime/dist/index.js

> yorkie@2.0.0 install /etc/praeco/node_modules/yorkie
> node bin/install.js

setting up Git hooks
done


> husky@1.3.1 install /etc/praeco/node_modules/husky
> node husky install

husky > setting up git hooks
husky > done

> node-sass@4.12.0 install /etc/praeco/node_modules/node-sass
> node scripts/install.js

Downloading binary from https://github.com/sass/node-sass/releases/download/v4.12.0/linux-x64-79_binding.node
Cannot download "https://github.com/sass/node-sass/releases/download/v4.12.0/linux-x64-79_binding.node":

HTTP error 404 Not Found

> uglifyjs-webpack-plugin@0.4.6 postinstall /etc/praeco/node_modules/vue-native-websocket/node_modules/uglifyjs-webpack-plugin
> node lib/post_install.js


> node-sass@4.12.0 postinstall /etc/praeco/node_modules/node-sass
> node scripts/build.js

Building: /usr/bin/node /etc/praeco/node_modules/node-gyp/bin/node-gyp.js rebuild --verbose --libsass_ext= --libsass_cflags= --libsass_ldflags= --libsass_library=
gyp info it worked if it ends with ok
...
gyp ERR! build error
gyp ERR! stack Error: not found: make
gyp ERR! stack     at getNotFoundError (/etc/praeco/node_modules/which/which.js:13:12)
gyp ERR! stack     at F (/etc/praeco/node_modules/which/which.js:68:19)
gyp ERR! stack     at E (/etc/praeco/node_modules/which/which.js:80:29)
gyp ERR! stack     at /etc/praeco/node_modules/which/which.js:89:16
gyp ERR! stack     at /etc/praeco/node_modules/isexe/index.js:42:5
gyp ERR! stack     at /etc/praeco/node_modules/isexe/mode.js:8:5
gyp ERR! stack     at FSReqCallback.oncomplete (fs.js:170:21)
gyp ERR! System Linux 4.19.76-linuxkit
gyp ERR! command "/usr/bin/node" "/etc/praeco/node_modules/node-gyp/bin/node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
gyp ERR! cwd /etc/praeco/node_modules/node-sass
gyp ERR! node -v v13.9.0
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok
Build failed with error code: 1
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules/vue-native-websocket/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! node-sass@4.12.0 postinstall: `node scripts/build.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the node-sass@4.12.0 postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2020-03-04T01_35_13_552Z-debug.log

I succeeded with nodejs v12(LTS) in previous comment. How about using LTS?

[root@834cbfe26cb1 praeco]# node -v
v12.16.1
[root@834cbfe26cb1 praeco]# npm -v
6.13.4

@johnsusek
Copy link
Owner

I have not tested with node 13. Manual installation is unsupported (that doesn't mean it won't work, it just means I don't have the time to help fix issues). I would highly recommend using the docker image or an environment close to the docker image.

@vikas-prabhakar
Copy link

@JumpyWizard404 try to execute npm install as non root user

@johnsusek
Copy link
Owner

You need to install the build tools on your machine to build node-sass:

gyp ERR! stack Error: not found: make

@nsano-rururu
Copy link
Collaborator

@JumpyWizard404

Added the manual installation method to the README.

@nsano-rururu nsano-rururu added the question Further information is requested label Feb 6, 2021
Repository owner locked and limited conversation to collaborators Oct 28, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

5 participants