سؤال

في ملف HTTP-CONF التالي كيفية إضافة المزيد من الإدخال لإضافة Bugzilla

أي 123.21.1.21 يذهب إلى موقع الويب الخاص بي و 123.21.1.21/bugzilla يشير إلى/opt/bugzilla

     <VirtualHost *:80>
     DocumentRoot /var/www/html/web
     ServerName Domainspace
     </VirtualHost>
     <Location "/">
     </Location>
هل كانت مفيدة؟

المحلول

أنا فقط ضبط Bugzilla في اليوم الآخر ، سيناريو مماثل. هنا هو 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>

تليها

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>

نصائح أخرى

يستخدم Alias.

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

أعلم أن هذا يتم الرد عليه ولكن هذا عمل بالنسبة لي على MacOSX

Alias /otherwork "/Volumes/anothervolume/otherwork"
<Directory "/Volumes/anothervolume/otherwork">
    Options Indexes FollowSymLinks ExecCGI Includes
    AllowOverride All
    Require all granted
    #more options here
</Directory>
مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top