0

I have the following supervisor program config:

[program:showvars]
environment=TESTVAR=hi,PYTHONPATH=/home/eric/python/tools/
command=python /home/eric/showvars.py

where showvars.py simply loops through the environment variables and prints their values:

import os
for param in os.environ.keys():
    print "%20s %s" % (param,os.environ[param])

I get the following (abridged) output:

         TESTVAR hi
      PYTHONPATH /

What could be resetting my PYTHONPATH?

erjiang
  • 296
  • 2
  • 10

1 Answers1

2

Surrounding the path with quotes fixes this:

[program:showvars]
environment=TESTVAR=hi,PYTHONPATH='/home/eric/python/tools/'
command=python /home/eric/showvars.py
erjiang
  • 296
  • 2
  • 10