I'm having trouble getting phantomjs to capture karma in an alpine docker container. I'm using node 6.10.2. I've installed phantomjs alpine from here. I'm using the following versions:
"karma": "^1.6.0",
"karma-coverage": "^1.1.1",
"karma-mocha": "^1.0.1",
"karma-mocha-reporter": "^2.0.0",
"karma-phantomjs-launcher": "^1.0.4",
"karma-webpack": "^2.0.3",
Inside my container when I run my tests I see the following output. (timestamps removed)
INFO [karma]: Karma v1.6.0 server started at http://0.0.0.0:9876/
INFO [launcher]: Launching browser PhantomJS with unlimited concurrency
INFO [launcher]: Starting browser PhantomJS
DEBUG [temp-dir]: Creating temp dir at /workspace/karma-1981971
DEBUG [launcher]: /usr/bin/phantomjs /workspace/karma-1981971/capture.js
WARN [launcher]: PhantomJS have not captured in 60000 ms, killing.
It then fails 2 times before exiting.
When I look at the contents of the tmp file capture.js it shows it is trying to open localhost:9876/?id=18274999 and inside my container I try to wget http://0.0.0.0:9876/ which does indeed succeed.
So I am very confused why PhantomJs fails to capture when I can indeed connect from within my container.
How should I go about debugging this? Any suggestions are greatly appreciated
I'm having the same problem in my build. I think using node 6.10.2 is the issue because I'm not seeing it happen on node 6.9.4