9

I've created a small Rails app that checks recularly the content of one of my sites with poltergeist and Capybara. Everything works great in dev on my mac. But when I test it on my production server I get the following server.

Capybara::Poltergeist::PhantomJSFailed (PhantomJS returned non-zero exit status 127. Make sure phantomjs runs successfully on your system. You can test this by just running the phantomjs command which should give you a Javascript REPL.):

Phantomjs works. I've tested it from the command-line. And what puzzles me more is that it also works when I run my method from the rails console on the production server.

Any idea?

jlfenaux
  • 3,263
  • 1
  • 26
  • 33
  • I've started experiencing a similar issue: PhantomJS works perfectly fine on my local machine and crashes on CI. Did you ever find a solution? – asfallows Aug 19 '13 at 13:14
  • I was having the same issues. 1. do you gave qt installed in production? – user588324 Oct 09 '13 at 17:45
  • Is it a $PATH issue? Sometimes system daemons run with a different $PATH to user services, so phantomjs may not be on your path when run from httpd – James_pic Jan 31 '14 at 15:59

1 Answers1

0

I had this problem too, Just I cant remember exactly what I did to recreate it. May have been me trying to do this on a virtual linux machine.

But this link https://github.com/jonleighton/poltergeist/issues/346 seems to detail 2 potential issues.

  1. Is probably to do with $path
  2. Could be a memory issue.
Dono
  • 656
  • 6
  • 12