summaryrefslogtreecommitdiff
path: root/strata
diff options
context:
space:
mode:
authorFrancisco Redondo Marchena <francisco.marchena@codethink.co.uk>2015-01-15 17:07:11 +0000
committerFrancisco Redondo Marchena <francisco.marchena@codethink.co.uk>2015-01-22 12:46:30 +0000
commitcb3c8c8219c373515cdcefbe96bd9ca77ed447c2 (patch)
tree93ad4a6b579756a6325688685efce48bf90592dd /strata
parenta76c02893ada1983d5d82ac3d59abe76472ec0f3 (diff)
downloaddefinitions-cb3c8c8219c373515cdcefbe96bd9ca77ed447c2.tar.gz
Add configuration file to load mod_wsgi from apache and enable shared libraries
Diffstat (limited to 'strata')
-rw-r--r--strata/apache-httpd-server/mod_wsgi.morph12
1 files changed, 12 insertions, 0 deletions
diff --git a/strata/apache-httpd-server/mod_wsgi.morph b/strata/apache-httpd-server/mod_wsgi.morph
index ef354a6c..48126787 100644
--- a/strata/apache-httpd-server/mod_wsgi.morph
+++ b/strata/apache-httpd-server/mod_wsgi.morph
@@ -3,8 +3,20 @@ kind: chunk
configure-commands:
- |
./configure --prefix="$PREFIX" \
+ --enable-shared \
--with-apxs=/usr/bin/apxs
build-commands:
- make
install-commands:
- PREFIX="$PREFIX" DESTDIR="$DESTDIR" make install
+post-install-commands:
+- |
+ install -D -m 644 /proc/self/fd/0 <<'EOF' "$DESTDIR$PREFIX"/httpd/conf.d/wsgi.conf
+ # NOTE: mod_wsgi can not coexist in the same apache process as
+ # mod_wsgi_python3. Only load if mod_wsgi_python3 is not
+ # already loaded.
+
+ <IfModule !wsgi_module>
+ LoadModule wsgi_module /usr/lib/httpd/modules/mod_wsgi.so
+ </IfModule>
+ EOF