File: //etc/httpd/sites-available/hobbyistgarage.com.conf
<VirtualHost *:80>
ServerName www.hobbyistgarage.com
ServerAlias hobbyistgarage.com
DocumentRoot /var/www/hobbyistgarage/public
<Directory " /var/www/hobbyistgarage/public">
Options Indexes FollowSymLinks MultiViews
AllowOverride all
Order Deny,Allow
Allow from all
Require all granted
RewriteEngine On
RewriteRule ^(.*)/$ /$1 [L,R=301]
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ index.php [QSA,L]
</Directory>
</VirtualHost>
<VirtualHost *:443>
ServerName www.hobbyistgarage.com
ServerAlias hobbyistgarage.com
SSLEngine on
SSLCertificateFile /etc/ssl/private/3ff72d8642d8c07a.crt
SSLCertificateKeyFile /etc/ssl/private/hobbyistgarage.key
DocumentRoot /var/www/hobbyistgarage/public
<Directory "/var/www/hobbyistgarage/public">
Options Indexes FollowSymLinks MultiViews
AllowOverride all
Order Deny,Allow
Allow from all
Require all granted
RewriteEngine On
RewriteRule ^(.*)/$ /$1 [L,R=301]
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ index.php [QSA,L]
<IfModule mod_mime.c>
AddType application/x-javascript .js
AddType text/css .css
</IfModule>
<IfModule mod_deflate.c>
AddOutputFilterByType DEFLATE text/css application/x-javascript text/x-component text/html text/plain text/xml application/javascript
<IfModule mod_setenvif.c>
BrowserMatch ^Mozilla/4 gzip-only-text/html
BrowserMatch ^Mozilla/4.0[678] no-gzip
BrowserMatch bMSIE !no-gzip !gzip-only-text/html
</IfModule>
</IfModule>
<filesMatch ".(js|css|jpg|jpeg|png|gif|ico|swf|woff|woff2|eot|ttf|svg)$">
Header set Cache-Control "max-age=31536000, public"
Header unset Last-Modified
Header unset ETag
</filesMatch>
</Directory>
</VirtualHost>