File: //etc/apache2/sites-available/ethnikamauricia.com.conf
# Virtual Hosts
<VirtualHost *:80>
ServerAdmin support@novotecs.com
ServerAlias www.ethnikamauricia.com
ServerName ethnikamauricia.com
#DocumentRoot
DocumentRoot /var/www/ethnikamauricia.com
<Directory "/var/www/ethnikamauricia.com">
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
allow from all
</Directory>
ErrorLog ${APACHE_LOG_DIR}/ethnikamauricia.com-error.log
CustomLog ${APACHE_LOG_DIR}/ethnikamauricia.com-access.log combined
RewriteEngine on
RewriteCond %{SERVER_NAME} =ethnikamauricia.com [OR]
RewriteCond %{SERVER_NAME} =www.ethnikamauricia.com
RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [END,NE,R=permanent]
</VirtualHost>
<IfModule mod_ssl.c>
<VirtualHost *:443>
ServerAdmin support@novotecs.com
ServerAlias www.ethnikamauricia.com
ServerName ethnikamauricia.com
#DocumentRoot
DocumentRoot /var/www/ethnikamauricia.com
<Directory "/var/www/ethnikamauricia.com">
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
allow from all
</Directory>
ErrorLog ${APACHE_LOG_DIR}/ethnikamauricia.com-error.log
CustomLog ${APACHE_LOG_DIR}/ethnikamauricia.com-access.log combined
SSLCertificateFile /etc/letsencrypt/live/ethnikamauricia.com/fullchain.pem
SSLCertificateKeyFile /etc/letsencrypt/live/ethnikamauricia.com/privkey.pem
Include /etc/letsencrypt/options-ssl-apache.conf
</VirtualHost>
</IfModule>