Rajeev
Rajeev

Reputation: 46899

multiple document root for httpd conf file

In the following http-conf file how to add on more entry to add bugzilla

i.e, 123.21.1.21 goes to my website and 123.21.1.21/bugzilla is pointed to /opt/bugzilla

     <VirtualHost *:80>
     DocumentRoot /var/www/html/web
     ServerName Domainspace
     </VirtualHost>
     <Location "/">
     </Location>

Upvotes: 0

Views: 13327

Answers (3)

visualex
visualex

Reputation: 756

I know this is answered but this worked for me on macosx

Alias /otherwork "/Volumes/anothervolume/otherwork"
<Directory "/Volumes/anothervolume/otherwork">
    Options Indexes FollowSymLinks ExecCGI Includes
    AllowOverride All
    Require all granted
    #more options here
</Directory>

Upvotes: 0

Doug Chamberlain
Doug Chamberlain

Reputation: 11341

I just set bugzilla up the other day, similar scenario. Here is my httpd.conf

NameVirtualHost xxx.xxx.xxx.local

<VirtualHost  xxx.xxx.xxx.local>
  ServerName  xxx.xxx.xxx.local
  DocumentRoot "C:/Apache2.2/htdocs"
</VirtualHost>

<VirtualHost  xxx.xxx.xxx.local>
  ServerName  xxx.xxx.xxx.local
  DocumentRoot "C:/bugzilla"
</VirtualHost>

followed by

Alias /bugzilla "C:\bugzilla"
<Directory "C:\bugzilla">
AddHandler cgi-script .cgi
Options +Indexes +ExecCGI
DirectoryIndex index.cgi
AllowOverride Limit FileInfo Indexes
Order allow,deny
Allow from all
</Directory>

Upvotes: 4

Pekka
Pekka

Reputation: 449385

Use Alias.

<VirtualHost *:80>
 DocumentRoot /var/www/html/web
 ServerName Domainspace
 Alias /bugzilla /opt/bugzilla
 </VirtualHost>

Upvotes: 1

Related Questions