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