diff options
author | Wojciech Polak <polak@gnu.org> | 2014-09-30 07:54:05 +0200 |
---|---|---|
committer | Wojciech Polak <polak@gnu.org> | 2014-09-30 07:54:05 +0200 |
commit | f6e2aa8085a3c479e49925d05a35128b2dcb3849 (patch) | |
tree | ca99363110022962e7792722b75487cacb47d54f | |
parent | 1dcdf3dc5107b961d1d9ad25a31efc01286d5b89 (diff) | |
download | glifestream-f6e2aa8085a3c479e49925d05a35128b2dcb3849.tar.gz glifestream-f6e2aa8085a3c479e49925d05a35128b2dcb3849.tar.bz2 |
Add wsgi.virtualenv.py
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | glifestream/wsgi.virtualenv.py | 28 |
2 files changed, 29 insertions, 0 deletions
@@ -5,6 +5,7 @@ bin/ include/ lib/ +lib64 settings.py static/thumbs static/upload diff --git a/glifestream/wsgi.virtualenv.py b/glifestream/wsgi.virtualenv.py new file mode 100644 index 0000000..c9ad02e --- /dev/null +++ b/glifestream/wsgi.virtualenv.py @@ -0,0 +1,28 @@ +# gLifestream Copyright (C) 2013, 2014 Wojciech Polak +# +# This program is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by the +# Free Software Foundation; either version 3 of the License, or (at your +# option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License along +# with this program. If not, see <http://www.gnu.org/licenses/>. + +import os +import sys + +SITE_ROOT = os.path.dirname(os.path.realpath(__file__)) +os.environ['DJANGO_SETTINGS_MODULE'] = 'glifestream.settings' + +activate_this = os.path.join(SITE_ROOT, '../bin/activate_this.py') +execfile(activate_this, dict(__file__=activate_this)) + +sys.path.insert(0, os.path.join(SITE_ROOT, '../')) + +from django.core.wsgi import get_wsgi_application +application = get_wsgi_application() |