aboutsummaryrefslogtreecommitdiff
path: root/roles/apache/files
diff options
context:
space:
mode:
Diffstat (limited to 'roles/apache/files')
-rw-r--r--roles/apache/files/000-default-ssl.conf11
-rw-r--r--roles/apache/files/000-default.conf9
2 files changed, 20 insertions, 0 deletions
diff --git a/roles/apache/files/000-default-ssl.conf b/roles/apache/files/000-default-ssl.conf
new file mode 100644
index 0000000..dcf8b8b
--- /dev/null
+++ b/roles/apache/files/000-default-ssl.conf
@@ -0,0 +1,11 @@
+<IfModule mod_ssl.c>
+ <VirtualHost _default_:443>
+ ServerAdmin webmaster@localhost
+
+ Redirect 404 /
+
+ Include ssl.conf
+ </VirtualHost>
+</IfModule>
+
+# vim: syntax=apache ts=4 sw=4 sts=4 sr noet
diff --git a/roles/apache/files/000-default.conf b/roles/apache/files/000-default.conf
new file mode 100644
index 0000000..922eb96
--- /dev/null
+++ b/roles/apache/files/000-default.conf
@@ -0,0 +1,9 @@
+<VirtualHost *:80>
+ ServerAdmin webmaster@localhost
+
+ RewriteEngine On
+ RewriteCond %{HTTPS} !=on
+ RewriteRule ^/?(.*) https://%{SERVER_NAME}/$1 [R,L]
+</VirtualHost>
+
+# vim: syntax=apache ts=4 sw=4 sts=4 sr noet