我创build了以下虚拟主机:
<VirtualHost *:80> ServerName testingsitehere.com ServerAlias www.testingsitehere.com DocumentRoot /www/vhosts/testingsitehere.com ErrorLog /www/Apache22/logs/error.log <Directory "/www/vhosts/testingsitehere.com"> Options All AllowOverride All order allow,deny allow from all </Directory> </VirtualHost>
并安装了BIND。
这是一个testing服务器,不是面向公众的,所以没有人可以访问这些。 它使用Web-Developer Server Suite(因此是C:/ www / vhosts文件夹path)。
我应该使用HOSTS文件上的BIND映射我的域到本地主机,还是应该像我以前一样继续使用HOSTS?
BIND实际上可以将域名/ DNS映射到本地主机,127.0.0.1还是我误解了?
干杯
如果你不是在本地networking/内部networking上服务,那么就不需要设置BIND了。 如果你正在运行的同一台机器上testing你的虚拟主机,使用%systemroot%\System32\drivers\etc\hosts就可以正常工作。
除了testingsitehere.com到127.0.0.1之外,还有什么额外的映射是你想的?