Tonu Mikk
tmikk at umn.edu
Wed Sep 12 15:16:49 EDT 2007
Hello, I hope that someone on mod_python mailing list can assist me with the Apache httpd.conf configuration. I would like to implement Apache virtual hosts with Roundup (http://roundup.sf.net) which in turn uses mod_python. My current httpd.conf configuration does not utilize Virtual hosts and serves following URLs http://rounduptest.dmc.umn.edu/roundup/dmc and http://rounduptest.dmc.umn.edu/roundup/telgrants. I would like to use URLs that would instead look like this: http://roundup.dmc.umn.edu/ http://telgrants.dmc.umn.edu/ The current portion httpd.conf related to Roundup is here. The directory permissions directives are there to only allow access to the files from within our organization. ################################################# # Roundup Issue tracker ################################################# # enable Python optimizations (like 'python -O') PythonOptimize On # let apache handle static files from 'html' directories AliasMatch /roundup/(.+)/@@file/(.*) C:/roundup/$1/html/$2 # everything else is handled by roundup web UI AliasMatch /roundup/([^/]+)/(?!@@file/)(.*) C:/roundup/$1/dummy.py/$2 # roundup requires a slash after tracker name - add it if missing RedirectMatch permanent /roundup/([^/]+)$ /roundup/$1/ # common settings for all roundup trackers <Directory /> Options None AllowOverride None Order deny,allow Deny from all </Directory> <Directory C:/roundup*> # Order allow,deny # Allow from all # AllowOverride None # Options None AllowOverride None Options None Order deny,allow Deny from all Allow from umn.edu Allow from 192.168 Allow from 131.212 Allow from 128.101 Allow from 160.94 Allow from 146.57 Allow from 134.84 Allow from localhost AddHandler python-program .py PythonHandler roundup.cgi.apache # uncomment the following line to see tracebacks in the browser # (note that *some* tracebacks will be displayed anyway) PythonDebug On </Directory> # roundup tracker homes <Directory C:/roundup/telgrants> PythonOption TrackerHome C:/roundup/telgrants </Directory> <Directory C:/roundup/dmc> PythonOption TrackerHome C:/roundup/dmc </Directory> #End of section by Tonu I experimented with virtual directory directives in httpd.config, but did not get them to work properly to serve Roundup pages with short URLs. Looking at some other examples that people had done in similar situations (as example: http://trac.edgewall.org/wiki/TracModPython) I realize that I will need mod_python directives inside the virtual host. I include the Virtual Host directives here to show that I started with. Would someone be able to translate the directives related to Roundup to the way they should look inside the virtual host? Thank you, Tonu # Virtual hosts NameVirtualHost 160.94.18.121:80 <VirtualHost 160.94.18.121:80> ServerName rounduptest.dmc.umn.edu DocumentRoot C:/roundup/dmc </VirtualHost> <VirtualHost 160.94.18.121:80> ServerName telgrantstest.dmc.umn.edu DocumentRoot C:/roundup/telgrants </VirtualHost>
|