From dbfa18431aaa73ed5f7c75b46e674a3656dc25bb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20Kr=C3=A4uter?= Date: Mon, 23 Jun 2014 15:33:40 +0200 Subject: [PATCH] Update wsgi.py.erb Fixed: "NameError: name 'os' is not defined" in wsgi template --- templates/wsgi.py.erb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/templates/wsgi.py.erb b/templates/wsgi.py.erb index 3bf4ab67..bb55740e 100644 --- a/templates/wsgi.py.erb +++ b/templates/wsgi.py.erb @@ -1,12 +1,12 @@ from __future__ import absolute_import +import os +import sys + os.environ['PUPPETBOARD_SETTINGS'] = '<%= @basedir %>/puppetboard/settings.py' activate_this = '<%= @basedir %>/virtenv-puppetboard/bin/activate_this.py' execfile(activate_this, dict(__file__=activate_this)) -import os -import sys - me = os.path.dirname(os.path.abspath(__file__)) # Add us to the PYTHONPATH/sys.path if we're not on it if not me in sys.path: