Ubuntu Server 14.04 – Apache2 Webserver – Multiple Sites

1. Change to Super User

2. Navigate to /var/www

3. Create 2 *TEST* directories.

4. Create a index.html in each.

You should now have a file structure like follows:

  • Site1.com
    • index.html
  • Site2.com
    • index.html

5. Change the directory to

and create an empty file by typing

6. In this file enter the following – this will apply to both site1 and site2.

7. Once the 2 files are created, we will then need to enable the 2 sites with Apache. To do this type in the following:

This should then tell Apache2 that there are new sites available.

8. We now need to restart the service to refresh the sites and webserver.

9. Testing, open up a web browser and type in the following:

site1.andersonfamilynetwork.com

or site2.andersonfamilynetwork.com

You should now see the 2 sites running from the same webserver.

To make these externally accessible, you will need to follow the previous guide I wrote up regarding PFSense etc.