diff options
author | mh <mh@immerda.ch> | 2008-11-08 20:21:46 +0000 |
---|---|---|
committer | mh <mh@immerda.ch> | 2008-11-08 20:21:46 +0000 |
commit | 7350f1f88d0d75cf2c98198c3559c39d7be8a709 (patch) | |
tree | 55194ec1153d05ed014fd22c5fe84f7bb1d9c642 /templates/vhosts/static | |
parent | 84827754f2feed2a7c92a0ecdf1d094fbed292bc (diff) |
make vhost template output nicier
Diffstat (limited to 'templates/vhosts/static')
-rw-r--r-- | templates/vhosts/static/OpenBSD.erb | 34 |
1 files changed, 16 insertions, 18 deletions
diff --git a/templates/vhosts/static/OpenBSD.erb b/templates/vhosts/static/OpenBSD.erb index b3b8342..b0054e6 100644 --- a/templates/vhosts/static/OpenBSD.erb +++ b/templates/vhosts/static/OpenBSD.erb @@ -5,36 +5,36 @@ <%- unless serveralias.to_s.empty? then -%> ServerAlias <%= serveralias %> <%- end -%> - DocumentRoot <%= documentroot %> + DocumentRoot <%= documentroot %>/ ErrorLog <%= logdir %>/error_log CustomLog <%= logdir %>/access_log combined - <%- if ssl_mode.to_s=='force' then %> + <%- if ssl_mode.to_s=='force' then -%> Redirect permanent / https://<%= servername %>/ - <%- end %> + <%- end -%> <%- if options.to_s != 'absent' or htpasswd_file.to_s != 'absent' then -%> - <Directory "<%= documentroot %>"> - <%- unless options.to_s == 'absent' then %> + <Directory "<%= documentroot %>/"> + <%- unless options.to_s == 'absent' then -%> Options <%= options %> - <%- end %> + <%- end -%> <%- unless htpasswd_file.to_s == 'absent' then -%> AuthType Basic AuthName "Access fuer <%= servername %>" AuthUserFile <%= htpasswd_path %> require valid-user - - <%- end %> + <%- end -%> </Directory> - <%- end %> + <%- end _%> <%- unless additional_options.to_s == 'absent' then -%> <%= additional_options %> <%- end -%> </VirtualHost> -<%- unless ssl_mode.to_s == 'false' then %> + +<%- unless ssl_mode.to_s == 'false' then -%> <VirtualHost *:443> Include conf.d/defaults.inc Include conf.d/ssl_defaults.inc @@ -42,24 +42,22 @@ <%- unless serveralias.to_s.empty? then -%> ServerAlias <%= serveralias %> <%- end -%> - DocumentRoot <%= documentroot %> + DocumentRoot <%= documentroot %>/ ErrorLog <%= logdir %>/error_log CustomLog <%= logdir %>/access_log combined - <%- if options.to_s != 'absent' or htpasswd_file.to_s != 'absent' then -%> - <Directory "<%= documentroot %>"> - <%- unless options.to_s == 'absent' then %> + <Directory "<%= documentroot %>/"> + <%- unless options.to_s == 'absent' then -%> Options <%= options %> - <%- end %> + <%- end -%> <%- unless htpasswd_file.to_s == 'absent' then -%> AuthType Basic AuthName "Access fuer <%= servername %>" AuthUserFile <%= htpasswd_path %> require valid-user - - <%- end %> + <%- end -%> </Directory> <%- end %> @@ -67,4 +65,4 @@ <%= additional_options %> <%- end -%> </VirtualHost> -<%- end %> +<%- end -%> |