Permalink
Browse files

htaccess: added https redirect & ignored files

  • Loading branch information...
dg committed Nov 21, 2018
1 parent 69fe01f commit 8b6c806cb5cb06d5c93207b1522dfffa6740aba7
Showing with 5 additions and 1 deletion.
  1. +5 −1 www/.htaccess
@@ -11,13 +11,17 @@ Require all granted
RewriteEngine On
# RewriteBase /

# use HTTPS
# RewriteCond %{HTTPS} !on
# RewriteRule .? https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]

# prevents files starting with dot to be viewed by browser
RewriteRule /\.|^\.(?!well-known/) - [F]

# front controller
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule !\.(pdf|js|ico|gif|jpg|png|css|rar|zip|tar\.gz|map)$ index.php [L]
RewriteRule !\.(pdf|js|ico|gif|jpg|jpeg|png|webp|svg|css|rar|zip|7z|tar\.gz|map|eot|ttf|otf|woff|woff2)$ index.php [L]
</IfModule>

# enable gzip compression

0 comments on commit 8b6c806

Please sign in to comment.