Hello,

I try to pack WSGI application into docker container. I use Alpine linux.
Everything works until I enable daemon mode with WSGIDaemonProcess, in this 
case I get "Segmentation fault".
This is reproducible with the simplest setup possible.

Dockerfile:
FROM alpine:3.4
RUN apk add --no-cache apache2-mod-wsgi && mkdir -p /run/apache2 && mkdir 
-p /wsgi
ADD wsgi-test.conf /etc/apache2/conf.d/
ADD wsgi-test.wsgi /wsgi/
CMD ["/bin/sh"]

wsgi-test.conf:
Listen 8080
<VirtualHost *:8080>
  ServerName localhost
  WSGIScriptAlias /test /wsgi/wsgi-test.wsgi
# WSGIDaemonProcess example.com processes=2 threads=2
# WSGIProcessGroup example.com
  <Directory /wsgi>
  Require all granted
  </Directory>
</VirtualHost>

wsgi-test.wsgi:
def application(environ, start_response):
    status = '200 OK'
    output = 'Hello World!\n'
    response_headers = [('Content-type', 'text/plain'),
                        ('Content-Length', str(len(output)))]
    start_response(status, response_headers)
    return [output]

This works as expected – I run "httpd -DFOREGROUND" inside the container 
and can curl http://docker:8080/test for 'Hello World!'.
If I uncomment daemon options, the same command gives:
/ # httpd -DFOREGROUND
AH00558: httpd: Could not reliably determine the server's fully qualified 
domain name, using 172.17.0.5. Set the 'ServerName' directive globally to 
suppress this message
Segmentation fault

 Any hints how to fix this?

-- 
You received this message because you are subscribed to the Google Groups 
"modwsgi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/modwsgi.
For more options, visit https://groups.google.com/d/optout.

Reply via email to