Change Default Directory Apache to Home

Kam, 04/28/2016 - 10:38 -- bonny
LAMP

Change Default Directory Apache from /var/www/html to /home/username/www:

$ sudo usermod -a -G www-data username

Change DocumentRoot /var/www/html to DocumentRoot /home/username/www

$ sudo nano /etc/apache2/sites-available/000-default.conf

Change Default directory on Apache Configuration

$ sudo nano /etc/apache2/apache2.conf

Change

Options Indexes FollowSymLinks
AllowOverride None
Require all granted

to

Options Indexes FollowSymLinks
AllowOverride None
Require all granted

$ sudo service apache2 restart