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

Errors during "sudo npm run start" command #85

Open
miguelguti80 opened this issue Jul 10, 2017 · 1 comment
Open

Errors during "sudo npm run start" command #85

miguelguti80 opened this issue Jul 10, 2017 · 1 comment

Comments

@miguelguti80
Copy link

Hello, I recive the following error while try to run "sudo npm run start" command:

[email protected] start /root/dasher
node app.js

module.js:328
throw err;
^

Error: Cannot find module './config/config.json'
at Function.Module._resolveFilename (module.js:326:15)
at Function.Module._load (module.js:277:25)
at Module.require (module.js:354:17)
at require (internal/module.js:12:17)
at Object. (/root/dasher/app.js:2:14)
at Module._compile (module.js:410:26)
at Object.Module._extensions..js (module.js:417:10)
at Module.load (module.js:344:32)
at Function.Module._load (module.js:301:12)
at Function.Module.runMain (module.js:442:10)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] start: node app.js
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] start 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/2017-07-10T08_04_56_484Z-debug.log

The debug.log says:

0 info it worked if it ends with ok
1 verbose cli [ '/usr/bin/nodejs', '/usr/local/bin/npm', 'run', 'start' ]
2 info using [email protected]
3 info using [email protected]
4 verbose run-script [ 'prestart', 'start', 'poststart' ]
5 info lifecycle [email protected]prestart: [email protected]
6 info lifecycle [email protected]
start: [email protected]
7 verbose lifecycle [email protected]start: unsafe-perm in lifecycle true
8 verbose lifecycle [email protected]
start: PATH: /usr/local/lib/node_modules/npm/bin/node-gyp-bin:/root/dasher/node_modules/.bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/snap/bin
9 verbose lifecycle [email protected]start: CWD: /root/dasher
10 silly lifecycle [email protected]
start: Args: [ '-c', 'node app.js' ]
11 silly lifecycle [email protected]start: Returned: code: 1 signal: null
12 info lifecycle [email protected]
start: Failed to exec start script
13 verbose stack Error: [email protected] start: node app.js
13 verbose stack Exit status 1
13 verbose stack at EventEmitter. (/usr/local/lib/node_modules/npm/lib/utils/lifecycle.js:289:16)
13 verbose stack at emitTwo (events.js:87:13)
13 verbose stack at EventEmitter.emit (events.js:172:7)
13 verbose stack at ChildProcess. (/usr/local/lib/node_modules/npm/lib/utils/spawn.js:40:14)
13 verbose stack at emitTwo (events.js:87:13)
13 verbose stack at ChildProcess.emit (events.js:172:7)
13 verbose stack at maybeClose (internal/child_process.js:821:16)
13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:211:5)
14 verbose pkgid [email protected]
15 verbose cwd /root/dasher
16 verbose Linux 4.4.0-43-Microsoft
17 verbose argv "/usr/bin/nodejs" "/usr/local/bin/npm" "run" "start"
18 verbose node v4.2.6
19 verbose npm v5.1.0
20 error code ELIFECYCLE
21 error errno 1
22 error [email protected] start: node app.js
22 error Exit status 1
23 error Failed at the [email protected] start script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 1, true ]

Thanks a lot!!

@elmedico27
Copy link

Looks like you're missing your config.json file. Once you've edited the config.example.json file, you'll need to rename it/make a copy and call it config.json. Make sure it stays in the ./dasher/config/ folder.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants