Note: I guess the bottle framework is not relevant here. Wsgi is.
I\'ve managed to configure my apache to work with wsgi and one-file web applicatio
I tried Graham's suggestion but it didn't work for me.
Here is what worked for me:
[BTW, I am working on OSX. Please adjust the paths, user, group according to your operating system]
/Library/WebServer/Documents/hello_app/app.wsgi:
import sys
sys.path.insert(0, "/Library/WebServer/Documents/hello_app")
import bottle
import hello
application = bottle.default_app()
/Library/WebServer/Documents/hello_app/hello.py:
from bottle import route
@route('/hello')
def hello():
return "Hello World!"
/etc/apache2/extra/httpd-vhosts.conf:
ServerName xyz.com
WSGIDaemonProcess hello_app user=_www group=_www processes=1 threads=5
WSGIScriptAlias /v1 /Library/WebServer/Documents/hello_app/app.wsgi
WSGIProcessGroup hello_app
WSGIApplicationGroup %{GLOBAL}
Order deny,allow
Allow from all
Don't forget to restart your apache server.