Closed geoHeil closed 8 years ago
@geoHeil our CI builds are on Ubuntu 14.04 and I run arch, so it's unlikely to be a linux or ubuntu specific issue.
The above error is the typescript compiler not being able to find the node typiings:
x220:~/code/clicker$ grep node typings.json
"node": "registry:dt/node#6.0.0+20160514165920",
I'll have a look with the docker file you've provided later on
replicated using the dockerfile provided
I just had to run typings install
as a separate step, so for some reason the post install hook is failing in your setup:
"postinstall": "ionic state restore && typings install && webdriver-manager update && cp test/karma-static/*.html node_modules/karma/static",
npm WARN cannot run in wd clicker@1.8.0 ionic state restore && typings install && webdriver-manager update && cp test/karma-static/*.html node_modules/karma/static (wd=/clicker)
Possibly relevant:
http://stackoverflow.com/questions/18136746/npm-install-failed-with-cannot-run-in-wd
If npm was invoked with root privileges, then it will change the uid to the user account or uid specified by the user config, which defaults to nobody. Set the unsafe-perm flag to run scripts with root privileges.
Which would make sense as I presume you're running as root (I am when I replicate, and there doesn't seem to be another user on your image)
npm install --unsafe-perms
did not work
Thanks a lot.
Adding
EDIT: --allow-root-install
to the postinstall line does the trick:--allow-root-install
doesn't actually work
The way forward seems to be just running npm run postinstall
after npm install
I'm not keen to put this in the repo as default as I'm not clear on the consequences of doing so. I don't think it's good practice to run anything as root (even in docker).
I will however put something in the readme and link this issue from the blog.
Nope you are right. I will change the docker file.
Sweet, closing
Hi
npm test
works fine on osx, but on Ubuntu it is failing with the following error:Here is a dockerfile https://gist.github.com/geoHeil/48cd94bf4d748fd8fd6d25de4c272157 which demonstrates a linux environment which leads to this error.