From 29517a83414f478a0e28a9fc57b178e35e9ba112 Mon Sep 17 00:00:00 2001 From: mh Date: Tue, 17 May 2011 23:42:56 +0200 Subject: this is now in the include file --- templates/vhosts/gitweb/gitweb.erb | 8 +++----- templates/vhosts/partials/header_default.erb | 15 +++++++++------ templates/vhosts/perl/perl.erb | 4 ---- templates/vhosts/php/php.erb | 4 ---- templates/vhosts/php_drupal/php_drupal.erb | 4 ---- templates/vhosts/php_gallery2/php_gallery2.erb | 4 ---- templates/vhosts/php_joomla/php_joomla.erb | 4 ---- templates/vhosts/php_mediawiki/php_mediawiki.erb | 6 ------ templates/vhosts/php_silverstripe/php_silverstripe.erb | 4 ---- templates/vhosts/php_simplemachine/php_simplemachine.erb | 4 ---- templates/vhosts/php_spip/php_spip.erb | 4 ---- templates/vhosts/php_typo3/php_typo3.erb | 4 ---- templates/vhosts/php_wordpress/php_wordpress.erb | 4 ---- templates/vhosts/proxy/proxy.erb | 2 -- templates/vhosts/redirect/redirect.erb | 2 -- templates/vhosts/static/static.erb | 2 -- templates/vhosts/webdav/webdav.erb | 4 ---- 17 files changed, 12 insertions(+), 67 deletions(-) (limited to 'templates/vhosts') diff --git a/templates/vhosts/gitweb/gitweb.erb b/templates/vhosts/gitweb/gitweb.erb index 5bcfeb5..6024d65 100644 --- a/templates/vhosts/gitweb/gitweb.erb +++ b/templates/vhosts/gitweb/gitweb.erb @@ -10,11 +10,11 @@ ServerAdmin <%= server_admin %> <%- end -%> DocumentRoot <%= documentroot %>/ - -<%= scope.function_template('apache/vhosts/partials/logs.erb') %> <%- if default_charset.to_s != 'absent' then -%> AddDefaultCharset <%= default_charset %> <%- end -%> + +<%= scope.function_template('apache/vhosts/partials/logs.erb') %> <%- if ssl_mode.to_s == 'force' then -%> RewriteEngine On RewriteCond %{HTTPS} !=on @@ -63,13 +63,11 @@ ServerAdmin <%= server_admin %> <%- end -%> DocumentRoot <%= documentroot %>/ - -<%= scope.function_template('apache/vhosts/partials/logs.erb') %> <%- if default_charset.to_s != 'absent' then -%> AddDefaultCharset <%= default_charset %> <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" +<%= scope.function_template('apache/vhosts/partials/logs.erb') %> SetEnv GITWEB_CONFIG <%= gitweb_config %> DirectoryIndex gitweb.cgi diff --git a/templates/vhosts/partials/header_default.erb b/templates/vhosts/partials/header_default.erb index 32eb006..05b2122 100644 --- a/templates/vhosts/partials/header_default.erb +++ b/templates/vhosts/partials/header_default.erb @@ -1,12 +1,15 @@ Include include.d/defaults.inc - <% if vhost_part == :ssl -%> +<% if vhost_part == :ssl -%> Include include.d/ssl_defaults.inc - <% end -%> +<% end -%> ServerName <%= servername %> - <% unless serveralias.to_s.empty? || (serveralias.to_s == 'absent') -%> +<% unless serveralias.to_s.empty? || (serveralias.to_s == 'absent') -%> ServerAlias <%= serveralias %> - <% end -%> - <% unless server_admin.to_s.empty? || (server_admin.to_s == 'absent') -%> +<% end -%> +<% unless server_admin.to_s.empty? || (server_admin.to_s == 'absent') -%> ServerAdmin <%= server_admin %> - <% end -%> +<% end -%> DocumentRoot <%= documentroot %>/ +<% if default_charset.to_s != 'absent' then -%> + AddDefaultCharset <%= default_charset %> +<% end -%> \ No newline at end of file diff --git a/templates/vhosts/perl/perl.erb b/templates/vhosts/perl/perl.erb index 1b49d62..ca46e80 100644 --- a/templates/vhosts/perl/perl.erb +++ b/templates/vhosts/perl/perl.erb @@ -84,8 +84,6 @@ AddDefaultCharset <%= default_charset %> <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" - <%- if run_mode.to_s =~ /(proxy\-|static\-)?itk/ -%> AssignUserId <%= run_uid+" "+run_gid %> @@ -225,8 +223,6 @@ AddDefaultCharset <%= default_charset %> <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" - <%- unless run_mode.to_s == 'static-itk' -%> /"> AllowOverride <%= allow_override %> diff --git a/templates/vhosts/php/php.erb b/templates/vhosts/php/php.erb index ae70a00..851bd52 100644 --- a/templates/vhosts/php/php.erb +++ b/templates/vhosts/php/php.erb @@ -93,8 +93,6 @@ AddDefaultCharset <%= default_charset %> <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" - /"> AllowOverride <%= allow_override %> <%- if options.to_s != 'absent' or do_includes.to_s == 'true' then -%> @@ -220,8 +218,6 @@ AddDefaultCharset <%= default_charset %> <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" - <%- if run_mode.to_s == 'static-itk' -%> /"> AllowOverride <%= allow_override %> diff --git a/templates/vhosts/php_drupal/php_drupal.erb b/templates/vhosts/php_drupal/php_drupal.erb index 7300695..9fbda55 100644 --- a/templates/vhosts/php_drupal/php_drupal.erb +++ b/templates/vhosts/php_drupal/php_drupal.erb @@ -114,8 +114,6 @@ <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" - /"> AllowOverride <%= allow_override %> <%- if options.to_s != 'absent' or do_includes.to_s == 'true' then -%> @@ -282,8 +280,6 @@ AddDefaultCharset <%= default_charset %> <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" - <%- if run_mode.to_s == 'static-itk' -%> /"> AllowOverride <%= allow_override %> diff --git a/templates/vhosts/php_gallery2/php_gallery2.erb b/templates/vhosts/php_gallery2/php_gallery2.erb index 22d56ad..d936445 100644 --- a/templates/vhosts/php_gallery2/php_gallery2.erb +++ b/templates/vhosts/php_gallery2/php_gallery2.erb @@ -101,8 +101,6 @@ <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" - /"> AllowOverride <%= allow_override %> <%- if options.to_s != 'absent' or do_includes.to_s == 'true' then -%> @@ -246,8 +244,6 @@ AddDefaultCharset <%= default_charset %> <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" - <%- if run_mode.to_s == 'static-itk' -%> /"> AllowOverride <%= allow_override %> diff --git a/templates/vhosts/php_joomla/php_joomla.erb b/templates/vhosts/php_joomla/php_joomla.erb index dfb8136..b83d910 100644 --- a/templates/vhosts/php_joomla/php_joomla.erb +++ b/templates/vhosts/php_joomla/php_joomla.erb @@ -103,8 +103,6 @@ <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" - /"> Include include.d/joomla.inc @@ -240,8 +238,6 @@ AddDefaultCharset <%= default_charset %> <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" - <%- if run_mode.to_s == 'static-itk' -%> /"> Include include.d/joomla.inc diff --git a/templates/vhosts/php_mediawiki/php_mediawiki.erb b/templates/vhosts/php_mediawiki/php_mediawiki.erb index af0ae8c..e8252b9 100644 --- a/templates/vhosts/php_mediawiki/php_mediawiki.erb +++ b/templates/vhosts/php_mediawiki/php_mediawiki.erb @@ -89,8 +89,6 @@ <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" - /"> AllowOverride <%= allow_override %> <%- if options.to_s != 'absent' or do_includes.to_s == 'true' then -%> @@ -210,10 +208,6 @@ <%- if default_charset.to_s != 'absent' then -%> AddDefaultCharset <%= default_charset %> - <%- end -%> - <%- if ssl_mode.to_s == 'force' then -%> - Header add Strict-Transport-Security "max-age=15768000" - <%- end -%> <%- if run_mode.to_s == 'static-itk' -%> /"> diff --git a/templates/vhosts/php_silverstripe/php_silverstripe.erb b/templates/vhosts/php_silverstripe/php_silverstripe.erb index eaf944a..dcc40aa 100644 --- a/templates/vhosts/php_silverstripe/php_silverstripe.erb +++ b/templates/vhosts/php_silverstripe/php_silverstripe.erb @@ -112,8 +112,6 @@ <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" - /"> AllowOverride <%= allow_override %> <%- if options.to_s != 'absent' or do_includes.to_s == 'true' then -%> @@ -275,8 +273,6 @@ AddDefaultCharset <%= default_charset %> <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" - <%- if run_mode.to_s == 'static-itk' -%> /"> AllowOverride <%= allow_override %> diff --git a/templates/vhosts/php_simplemachine/php_simplemachine.erb b/templates/vhosts/php_simplemachine/php_simplemachine.erb index 5d7c87e..df04f77 100644 --- a/templates/vhosts/php_simplemachine/php_simplemachine.erb +++ b/templates/vhosts/php_simplemachine/php_simplemachine.erb @@ -87,8 +87,6 @@ <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" - /"> AllowOverride <%= allow_override %> <%- if options.to_s != 'absent' or do_includes.to_s == 'true' then -%> @@ -208,8 +206,6 @@ AddDefaultCharset <%= default_charset %> <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" - <%- if run_mode.to_s == 'static-itk' -%> /"> AllowOverride <%= allow_override %> diff --git a/templates/vhosts/php_spip/php_spip.erb b/templates/vhosts/php_spip/php_spip.erb index a4ffd19..644c743 100644 --- a/templates/vhosts/php_spip/php_spip.erb +++ b/templates/vhosts/php_spip/php_spip.erb @@ -93,8 +93,6 @@ <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" - /"> AllowOverride <%= allow_override %> <%- if options.to_s != 'absent' or do_includes.to_s == 'true' then -%> @@ -220,8 +218,6 @@ AddDefaultCharset <%= default_charset %> <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" - <%- if run_mode.to_s == 'static-itk' -%> /"> AllowOverride <%= allow_override %> diff --git a/templates/vhosts/php_typo3/php_typo3.erb b/templates/vhosts/php_typo3/php_typo3.erb index 1fec8e7..fd7d530 100644 --- a/templates/vhosts/php_typo3/php_typo3.erb +++ b/templates/vhosts/php_typo3/php_typo3.erb @@ -100,8 +100,6 @@ <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" - /"> AllowOverride <%= allow_override %> <%- if options.to_s != 'absent' or do_includes.to_s == 'true' then -%> @@ -235,8 +233,6 @@ AddDefaultCharset <%= default_charset %> <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" - <%- if run_mode.to_s == 'static-itk' -%> /"> AllowOverride <%= allow_override %> diff --git a/templates/vhosts/php_wordpress/php_wordpress.erb b/templates/vhosts/php_wordpress/php_wordpress.erb index fe713c8..b8d7b5e 100644 --- a/templates/vhosts/php_wordpress/php_wordpress.erb +++ b/templates/vhosts/php_wordpress/php_wordpress.erb @@ -89,8 +89,6 @@ <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" - /"> AllowOverride <%= allow_override %> <%- if options.to_s != 'absent' or do_includes.to_s == 'true' then -%> @@ -213,8 +211,6 @@ AddDefaultCharset <%= default_charset %> <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" - <%- if run_mode.to_s == 'static-itk' -%> /"> AllowOverride <%= allow_override %> diff --git a/templates/vhosts/proxy/proxy.erb b/templates/vhosts/proxy/proxy.erb index 1b1afd0..d89fb80 100644 --- a/templates/vhosts/proxy/proxy.erb +++ b/templates/vhosts/proxy/proxy.erb @@ -48,8 +48,6 @@ <%= scope.function_template('apache/vhosts/partials/logs.erb') %> - Header add Strict-Transport-Security "max-age=15768000" - <%= scope.function_template('apache/vhosts/partials/mod_security.erb') %> diff --git a/templates/vhosts/redirect/redirect.erb b/templates/vhosts/redirect/redirect.erb index 43cfa02..c9729d3 100644 --- a/templates/vhosts/redirect/redirect.erb +++ b/templates/vhosts/redirect/redirect.erb @@ -35,8 +35,6 @@ <%= scope.function_template('apache/vhosts/partials/logs.erb') %> - Header add Strict-Transport-Security "max-age=15768000" - Redirect permanent / https://<%= options %> diff --git a/templates/vhosts/static/static.erb b/templates/vhosts/static/static.erb index db5f102..287f413 100644 --- a/templates/vhosts/static/static.erb +++ b/templates/vhosts/static/static.erb @@ -57,8 +57,6 @@ AddDefaultCharset <%= default_charset %> <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" - /"> AllowOverride <%= allow_override %> <%- if options.to_s != 'absent' or do_includes.to_s == 'true' then -%> diff --git a/templates/vhosts/webdav/webdav.erb b/templates/vhosts/webdav/webdav.erb index eb12e36..61ac41d 100644 --- a/templates/vhosts/webdav/webdav.erb +++ b/templates/vhosts/webdav/webdav.erb @@ -93,8 +93,6 @@ <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" - DAVLockDB <%= real_dav_db_dir %>/DAVLock /"> Dav on @@ -191,8 +189,6 @@ AddDefaultCharset <%= default_charset %> <%- end -%> - Header add Strict-Transport-Security "max-age=15768000" - <%= scope.function_template('apache/vhosts/partials/mod_security.erb') %> <%- unless additional_options.to_s == 'absent' then -%> -- cgit v1.2.3