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

kong-dashboard start fails on local install #36

Closed
RRMoelker opened this issue Apr 12, 2016 · 2 comments
Closed

kong-dashboard start fails on local install #36

RRMoelker opened this issue Apr 12, 2016 · 2 comments

Comments

@RRMoelker
Copy link

When not installing globally the server will not come up.

Steps taken:

npm install kong-dashboard
npm install grunt

(notice another issue, grunt must also be installed)

Next when trying to run the local version of the dashboard I get an error:

$ ./node_modules/.bin/kong-dashboard start -p 8000
Launching webserver
<project_root>/node_modules/kong-dashboard/lib/kong-dashboard.js:98
        throw err;
        ^

Error: Command failed: /bin/sh -c <project_root>/node_modules/kong-dashboard/lib/../node_modules/.bin/serve --port 8000 --no-logs --no-icons <project_root>/node_modules/kong-dashboard/lib/../public
/bin/sh: <project_root>/node_modules/kong-dashboard/lib/../node_modules/.bin/serve: No such file or directory

    at ChildProcess.exithandler (child_process.js:213:12)
    at emitTwo (events.js:100:13)
    at ChildProcess.emit (events.js:185:7)
    at maybeClose (internal/child_process.js:821:16)
    at Socket.<anonymous> (internal/child_process.js:319:11)
    at emitOne (events.js:90:13)
    at Socket.emit (events.js:182:7)
    at Pipe._onclose (net.js:469:12)

Notice I replaced my project root absolute path with: <project_root>. And my node version is as follows:

$ node --version
v5.5.0
@RRMoelker
Copy link
Author

The culprit is the "hardcoded" relative path on the line https://github.com/PGBI/kong-dashboard/blob/master/lib/kong-dashboard.js#L33

This does not work for the flat dependencies in the newer node versions

@PGBI
Copy link
Owner

PGBI commented Dec 15, 2017

In older version of Kong-Dashboard, there were no guidance on which version(s) of node you needed because it wasn't tested.

This has been improved with Kong-Dashboard v3 for which you should not get this kind of error as long as you use node >= 6.

@PGBI PGBI closed this as completed Dec 15, 2017
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