aboutsummaryrefslogtreecommitdiffstats
path: root/server.py
diff options
context:
space:
mode:
authormjfernez <mjfernez@gmail.com>2021-06-07 19:47:59 -0400
committermjfernez <mjfernez@gmail.com>2021-06-07 19:48:59 -0400
commita4ef784946330abc6aed8e03accdf7541881df0f (patch)
treef0f191554f09e92feedae1b06bbb013c801c2b25 /server.py
parente36167843d8b23c057d244d38a7f96b584db2912 (diff)
downloadezcms-a4ef784946330abc6aed8e03accdf7541881df0f.tar.gz
wsgi compatibility
Moves the setup() function outside of main so the app is setup before a wrapper runs it. Also fixes deployment tutorial in the README
Diffstat (limited to 'server.py')
-rw-r--r--server.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/server.py b/server.py
index 8614fe3..21ecb2f 100644
--- a/server.py
+++ b/server.py
@@ -192,7 +192,7 @@ def setup():
app.config.update({'DOMAIN': siteconfig.DOMAIN})
app.config.update({'HOME_TITLE': siteconfig.HOME_TITLE})
-
+# Need to come first to be compatible with wsgi
+setup()
if __name__ == '__main__':
- setup()
- app.run(host=siteconfig.HOST, port=siteconfig.PORT)
+ app.run()