tags:

views:

55

answers:

1

I run Apache 2 with WSGI (for a Django-app) on a Ubuntu box. I want to use Nagios for server monitoring, and for this purpose it seems I have to add PHP support to Apache.

When I installed Apache 2, I did this:

apt-get install apache2 apache2.2-common apache2-mpm-worker apache2-threaded-dev libapache2-mod-wsgi python-dev

Available modules for apache2 are these:

/etc/apache2/mods-available$ ls

actions.conf      authn_default.load    cache.load           deflate.conf        filter.load
mime.conf         proxy_ftp.load        suexec.load          actions.load        authn_file.load
cern_meta.load    deflate.load          headers.load         mime.load           proxy_http.load
unique_id.load    alias.conf            authnz_ldap.load     cgi.load            dir.conf
ident.load        mime_magic.conf       rewrite.load         userdir.conf        alias.load
authz_dbm.load    cgid.conf             dir.load             imagemap.load       mime_magic.load
setenvif.conf     userdir.load          asis.load            authz_default.load  cgid.load
disk_cache.conf   include.load          negotiation.conf     setenvif.load       usertrack.load
auth_basic.load   authz_groupfile.load  charset_lite.load    disk_cache.load     info.conf
negotiation.load  speling.load          version.load         auth_digest.load    authz_host.load
dav.load          dump_io.load          info.load            proxy.conf          ssl.conf
vhost_alias.load  authn_alias.load      authz_owner.load     dav_fs.conf         env.load
ldap.load         proxy.load            ssl.load             wsgi.conf           authn_anon.load
authz_user.load   dav_fs.load           expires.load         log_forensic.load   proxy_ajp.load
status.conf       wsgi.load             authn_dbd.load       autoindex.conf      dav_lock.load
ext_filter.load   mem_cache.conf        proxy_balancer.load  status.load         authn_dbm.load
autoindex.load    dbd.load              file_cache.load      mem_cache.load      proxy_connect.load
substitute.load

What is the best way for me to add PHP support to Apache 2 without breaking my current installation and configuration?

A: 

IS the issue your referring to the Python WSGi.

if so take a look here to see if this helps you, Im not fully update with Python so not sure but hope it can help.

--

This module allows you to run PHP processes inside of Python, using a WSGI gateway. This way PHP applications can appear like normal Python WSGI applications, and WSGI middleware routing and filters can all be applied in front of them. For instance, WSGI middleware-based authentication or authorization, routing, deployment, or styling filters (like WSGIOverlay).

http://pythonpaste.org/wphp/

RobertPitt

related questions