My Apache is working fine, virtual hosts are working as expected. My operating system is Windows 7.
However, I have one problem that I am trying to find an answer to, and Google has not yielded much - for Windows in any case, only for Linux (which is not applicable in this case).
How to add new virtual hosts without restarting the server?
(Apache 2.2 version is what I am doing now)
I add new hosts to the host file and files in vhosts, for example:
<VirtualHost *:80> ServerName host1.tld ServerAlias www.host1.tld DocumentRoot /www/vhosts/host1.tld ErrorLog /www/Apache22/logs/error.log <Directory "/www/vhosts/host1.tld"> Options All AllowOverride All order allow,deny allow from all </Directory>
<VirtualHost *:80> ServerName mywebsite.com ServerAlias www.mywebsite.com DocumentRoot /www/vhosts/mywebsite.com ErrorLog /www/Apache22/logs/error.log <Directory "/www/vhosts/mywebsite.com"> Options All AllowOverride All order allow,deny allow from all </Directory>
Has anyone been in a similar decision, and if so, what is your advice?
source share