Apache virtual host

Create a new document in the apache config folder with the name of your site you want to link.

sudo nano /etc/apache2/sites-available/mysite.conf

Add the follwing content to the file

<VirtualHost *:80>
  ServerName mysite.com
  DocumentRoot /var/www/mysite/

  <Directory />
    Options FollowSymLinks
    AllowOverride All

  <Directory /var/www/mysite/>
    Options FollowSymLinks MultiViews
    AllowOverride All
    Order allow,deny
    allow from all


Enable this new virtual host with the following command. Change it to your filename.

sudo a2ensite mysite.conf

Now we need to restart the apache server.

sudo service apache restart