Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
Honcho fails on Heroku because, USER variable is not set #33
Tested version: 0.4.0
Steps to reproduce: run Honcho on Heroku, for example by putting "web: honcho -f ProcfileHoncho start" into your Procfile and "honcho==0.4.0" into your requirements.txt.
Actual behaviour: following error message is printed into heroku log:
Expected behaviour: tasks defined in ProcfileHoncho are started correctly
Temporary workaround: define USER variable on heroku:
Thanks for reporting this. It should be pretty easy to fix — I'll try and get to it soon.
Out of interest, can I ask why you're using honcho on Heroku rather than using Heroku's native Procfile support?
On Mon, Apr 1, 2013 at 7:07 PM, Radek Dostál firstname.lastname@example.org
Thank you very much for offering the fix!!!
Of course: I am just being cheap during development and I am running multiple processes within one Dyno using approach described at http://heyman.info/2012/dec/6/heroku-multiple-processes-single-dyno-with-foreman/ with one modification. I did not want to be mix ruby and python, so I rather decided to use honcho than foreman.
FWIW, the same issue existed on Windows and there was a tiny fix just for this here:
But frankly it puzzles me as to why a modern posix shell would not have USER defined... though this is a possibility and I wonder is using LOGNAME as fallback if USER is not there would work, possibly on Heroku too.
This thread shed some light on the topic: http://www.unix.com/shell-programming-scripting/152400-unix-user-logname-environment-variables.html
Samba for instance tests both: USER then LOGNAME: http://www.samba.org/samba/docs/man/manpages-3/smbclient.1.html