I am under rvm.
I have god.
It starts resque.
Resque job opens an IO.popen
to the local system program, sends it some text, gets some text back from the stream, analyses it a bit, closes the IO.
So: when I run resque as rake resque:work
— it's ok, everything works.
When I start resque from god run from user, it works.
Now I have made god working from init.d, made rvm wrapper, start it as sudo... So now the communication with IO
is somehow broken. Resque failed web-report says
Unexpected response format
/home/dakemen/.rvm/gems/ruby-2.0.0-p0/bundler/gems/go_gtp-5cd5a4de65cb/lib/go/gtp.rb:451:in `send_command'
I have some other resque jobs, that do not do anything with IO
. They work.
The gem I use to open IO
to the local application is
https://github.com/JEG2/go_gtp/blob/master/lib/go/gtp.rb
=========
Experiment:
So, all resque workers are started as sudo. Ok. And the worker refers to gnugo
.
user$ gnugo
GNU Go 3.8 and so on works great
user$ sudo gnugo
sudo: gnugo: command not found (WHY?)
user$ sudo echo $PATH
.......... /usr/games:/usr/local/games