Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am using apache with mod_wsgi (python3) on ubuntu 12.04.

I have a python app (bottle) which is at

In my python app I have routes like

I would like a path to resolve to a php app (simple machine forums)

Ideally I would like to use apache to handle the forum part and pass it to php (instead of coding it in the python app). Don't know if it's possible.

I'm new to this, I have read but I don't understand how to use it.

Here is my apache conf for the mod_wsgi app, I don't know how to specify the PHP portion.

<VirtualHost *:80>
ServerAlias *

RewriteEngine On
RewriteCond %{HTTP_HOST} !^www\.
RewriteRule ^(.*)$ http://www.%{HTTP_HOST}$1 [R=301,L]

WSGIDaemonProcess ex user=www-data group=www-data processes=1 threads=5
WSGIScriptAlias / /var/www/vhosts/ex/app.wsgi

<Directory /var/www/vhosts/ex>
    WSGIProcessGroup ex
    WSGIApplicationGroup %{GLOBAL}
    Order deny,allow
    Allow from all
share|improve this question
up vote 0 down vote accepted

you can try something like:

Alias /forum "/var/www/forum/"

<Directory "/var/www/forum/">
Order Deny,Allow
Deny from all
share|improve this answer
I just had to change Deny from all to Allow from all. Worked like a charm. – Lazik Nov 7 '13 at 15:28

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.