I am working on configuring Apache virtual hosts for the first time. I configured apache to use virtual hosts using this tutorial. When I restart apache it says the document root for one of my "virtual" links does not exist -- even though the file exists on my system. Why is Apache saying this? How can I fix it?
prompt$ sudo apachectl -k restart
Warning: DocumentRoot [/usr/docs/dummy-host.example.com] does not exist
Warning: DocumentRoot [/usr/docs/dummy-host2.example.com] does not exist
httpd: Could not reliably determine the server's fully qualified domain name, using Abrams-MacBook-Air-3.local for ServerName
prompt$ cat /usr/docs/dummy-host.example.com
<p> it works </p>
mv /usr/docs/dummy-host.example.com /usr/docs/index.html mkdir /usr/docs/dummy-host.example.com mv /usr/docs/index.html /usr/docs/dummy-host.example.com/index.html
This will rename your file to a proper index.html file, create the subdirectory you actually want and then file the new file under the host directory like you actually want.