From f14fd057987b5489228a40444c3a101768c5b6bb Mon Sep 17 00:00:00 2001 From: mh Date: Tue, 22 Feb 2011 22:59:40 +0100 Subject: first way to a unified partial based vhost template --- manifests/vhost/template.pp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'manifests/vhost/template.pp') diff --git a/manifests/vhost/template.pp b/manifests/vhost/template.pp index b0c08f9..303de0e 100644 --- a/manifests/vhost/template.pp +++ b/manifests/vhost/template.pp @@ -75,6 +75,7 @@ define apache::vhost::template( $run_uid = 'absent', $run_gid = 'absent', $template_mode = 'static', + $template_partial = 'absent', $ssl_mode = false, $mod_security = true, $mod_security_relevantonly = true, @@ -174,7 +175,10 @@ define apache::vhost::template( } if $ensure != 'absent' { Apache::Vhost::File[$name]{ - content => template("apache/vhosts/$template_mode/$operatingsystem.erb") + content => $template_partial ? { + 'absent' => template("apache/vhosts/$template_mode/$operatingsystem.erb"), + default => template("apache/vhosts/default.erb"), + } } } } -- cgit v1.2.3