From aecd757d6c8bb9b29509089076b560d4fa11323a Mon Sep 17 00:00:00 2001 From: Finn Christiansen Date: Tue, 7 Nov 2023 20:54:27 +0100 Subject: [PATCH] :sparkles: update wsgi file for virtual environment --- reminder.wsgi | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/reminder.wsgi b/reminder.wsgi index 1fc0521..3672d3e 100644 --- a/reminder.wsgi +++ b/reminder.wsgi @@ -1,6 +1,13 @@ +#!/usr/bin/python import os import sys -sys.path.insert(1, os.path.dirname(__file__)) +import logging +logging.basicConfig(stream=sys.stderr) +sys.path.insert(0, os.path.dirname(__file__)) +activate_this = os.path.join(os.path.dirname(__file__), 'bin/activate_this.py') +with open(activate_this) as file_: + exec(file_.read(), dict(__file__=activate_this)) + from app import create_app def application(environ, start_response):