xampp vhost 配置多虛擬機器主機

來源:互聯網
上載者:User

配置虛擬機器主機給aupair和Under a bus<br />使用同一 IP:PORT,根據不同url來區分不同虛擬機器主機,配置步驟如下:<br />1、c:/WINDOWS/system32/drivers/etc目錄下的host檔案,添加配置資訊如下:<br /> 127.0.0.1 www.aupair.net<br /> 127.0.0.1 www.uab.net<br />要配置apache的httpd.conf設定檔:<br />#如果要基於url的多虛擬機器,必須要有這個配置<br />NameVirtualHost *:80<br />#VirtualHost For Under A Bus<br /><VirtualHost *:80><br /> ServerAdmin nailwl86@gmail.com<br /> DocumentRoot F:/WebRoot/webuab<br /> #here is the url, you should synchronize it with the host configuration<br /> ServerName www.uab.net<br /> ErrorLog logs/uabdev.5ims.net-error_log<br /> CustomLog logs/uabdev.5ims.net-access_log common<br /> <Directory /><br /> Options FollowSymLinks MultiViews<br /> AllowOverride All<br /> Order allow,deny<br /> Allow from All<br /> </Directory><br /> <Directory "F:/WebRoot/webuab/"><br /> Options FollowSymLinks<br /> AllowOverride All<br /> Order allow,deny<br /> Allow from All<br /> </Directory><br /></VirtualHost><br />#VirtualHost For Aupair<br /><VirtualHost *:80><br /> ServerAdmin nailwl86@gmail.com<br /> DocumentRoot F:/WebRoot/aupair<br /> #here is the url, you should synchronize it with the host configuration<br /> ServerName www.aupair.net<br /> ErrorLog logs/aupairdev.5ims.net-error_log<br /> CustomLog logs/aupairdev.5ims.net-access_log common<br /> <Directory /><br /> Options FollowSymLinks MultiViews<br /> AllowOverride All<br /> Order allow,deny<br /> Allow from All<br /> </Directory><br /> <Directory "F:/WebRoot/aupair/"><br /> Options FollowSymLinks<br /> AllowOverride All<br /> Order allow,deny<br /> Allow from All<br /> </Directory><br /></VirtualHost><br />重新啟動apache,<br />分別在瀏覽器中輸入: </p><p>http://www.uab.net</p><p>http://www.aupair.net</p><p> 

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.