Brad Fuller wrote:
> Matthew Gillen wrote:
>> Brad Fuller wrote:
>>   
>>> I've googled for this and can't find the answer. I would think this
>>> would be a common config, but so far have found nothing. Apologies if
>>> it's out there and I just haven't found it yet.
>>>
>>> I would like to set up multiple, separate projects thru a virtual host
>>> that uses a specific port. Can that be done?
>>>     
>>
>> I don't see why not.  See
>> http://projects.edgewall.com/trac/wiki/TracModPython
>> (the "Setting up multiple projects" section)
>>
>> You can use the Location directive specified within a Virtual Host.
>>   
> Ok, how do you use a location directive specific to a virtual host? Can
> the <Location> directive be _inside_ the <VirtualHost> directive?  I
> thought it had to be outside.

The link above to the Trac Guide has an example:
---------------------

Virtual Host Configuration

Below is the sample configuration required to set up your trac as a virtual
server (i.e. when you access it at the URLs like http://trac.mycompany.com):

<VirtualHost * >
    DocumentRoot /var/trac/myproject
    ServerName trac.mycompany.com
    <Location />
        SetHandler mod_python
        PythonHandler trac.web.modpython_frontend
        PythonOption TracEnv /var/trac/myproject
        PythonOption TracUriRoot /
    </Location>
    <Location /login>
        AuthType Basic
        AuthName "MyCompany Trac Server"
        AuthUserFile /var/trac/myproject/.htusers
        Require valid-user
    </Location>
</VirtualHost>

---------------------

Matt
_______________________________________________
Trac mailing list
[email protected]
http://lists.edgewall.com/mailman/listinfo/trac

Reply via email to