Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I can't seem to figure out how to append to the default path in a supervisord program config.

I can reset the path:


But when I try:


I see that supervisord doesn't evaluate $PATH.

Google wasn't a big help on this for some reason, I cannot believe I'm the first person to need this.

Supervisord must have support for this, any idea what it is?

share|improve this question
have you found a solution for this problem? I just have the same issue – ascobol Jan 16 '12 at 16:07
@ascobol nope, I've hardcoded the path I need, for now – Prody Jan 17 '12 at 10:36
supervisord don't run shell to preprocess variables in the config file, so you can't use shell expressions to expand variables. Although there is a patch that allows to do %($PATH) and it was discussed in mailing lists back in 2011 but AFAIK it is still not included to the mainline source tree. As a workaround you can create a script that will setup environment and execute a command supplied in arguments. Then you just run the script from the supervisord like command /usr/local/bin/ program_name arguments – Dmitry Vasilyanov Dec 2 '12 at 17:49
There is a significant drawback to the shell wrapper solution - when supervisor will try to stop the process using INT or KILL, the signal will be received by the bash script and not the actual wrapped program. This may lead (and leads in my case) to dangling processes. – stoiczek Apr 15 '14 at 19:34
@stoiczek easy problem to solve. Use exec at the end of the bash script, do not just run the command regularly. So exec server --args. You see it in upstart jobs invariably. – CameronNemo Jul 1 '14 at 17:27
up vote 9 down vote accepted

This feature has been added to Supervisor recently


See also

share|improve this answer
But it has not been released (tagged) yet: – tersmitten Dec 1 '15 at 12:51
It's been tagged yesterday: – tersmitten Dec 2 '15 at 9:50

I reviewed the documentation and agree with Dmitry.

The current answer is: supervisor doesn't do this directory, but creating a wrapper script will help.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.