Apache2 – VirtualHost with .htaccess

Create a virtual host configuration file:

<VirtualHost *:80>
    DocumentRoot "/var/www/html/site"
    ServerName artem.services

    <Directory /var/www/html/site>
        Options FollowSymLinks
        AllowOverride All
        Order allow,deny
        Allow from all
    </Directory>
</VirtualHost>

Activate the "mod_rewrite" module:

a2enmod rewrite

And restart Apache2:

systemctl restart apache2

Tagged: Tags

Subscribe
Notify of
guest

0 Comments
Inline Feedbacks
View all comments