Skip to content

Commit 7745490

Browse files
lukaszachyphracek
authored andcommitted
mod-wsgi-test-app compatible with mod_wsgi 6.0.0
Keep it working with older mod_wsgi
1 parent b4f8bf0 commit 7745490

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

  • examples/mod-wsgi-test-app

examples/mod-wsgi-test-app/app.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
import os
2-
import mod_wsgi.server
2+
try:
3+
import mod_wsgi.express.cli as server_wrapper
4+
except ImportError:
5+
import mod_wsgi.server as server_wrapper
36

4-
mod_wsgi.server.start(
7+
server_wrapper.start(
58
'--log-to-terminal',
69
'--port', '8080',
710
'--trust-proxy-header', 'X-Forwarded-For',

0 commit comments

Comments
 (0)