diff options
author | mh <mh@immerda.ch> | 2008-12-01 22:11:12 +0000 |
---|---|---|
committer | mh <mh@immerda.ch> | 2008-12-01 22:11:12 +0000 |
commit | 399d57096b6c9dc956e90df422d38fdb4648458f (patch) | |
tree | 8a9c44c7d5a9f9ef906dab471cdd1e2712d5e984 /manifests/defines/vhost_varieties.pp | |
parent | 392ff8c6a909ca32431b9b65aae89c9138375330 (diff) |
added perl vhost definition
Diffstat (limited to 'manifests/defines/vhost_varieties.pp')
-rw-r--r-- | manifests/defines/vhost_varieties.pp | 65 |
1 files changed, 65 insertions, 0 deletions
diff --git a/manifests/defines/vhost_varieties.pp b/manifests/defines/vhost_varieties.pp index ba104db..b991fce 100644 --- a/manifests/defines/vhost_varieties.pp +++ b/manifests/defines/vhost_varieties.pp @@ -142,3 +142,68 @@ define apache::vhost::php::standard( mod_security => $mod_security, } } + +define apache::vhost::perl( + $domain = 'absent', + $domainalias = 'absent', + $path = 'absent', + $owner = root, + $group = 0, + $documentroot_owner = apache, + $documentroot_group = 0, + $documentroot_mode = 0750, + $allow_override = 'None', + $cgi_binpath = 'absent', + $options = 'absent', + $additional_options = 'absent', + $mod_security = 'true', + $vhost_mode = 'template', + $vhost_source = 'absent', + $vhost_destination = 'absent', + $htpasswd_file = 'absent', + $htpasswd_path = 'absent' +){ + # cgi_bin path + case $cgi_binpath { + 'absent': { + $real_cgi_binpath = "${path}/cgi-bin" } + } + default: { $real_cgi_binpath = $cgi_binpath + } + file{$real_cgi_binpath: + ensure => directory, + owner => $documentroot_owner, + group => $documentroot_group, + mode => $documentroot_mode; + } + + # create webdir + apache::vhost::webdir{$name: + path => $path, + owner => $owner, + group => $group, + documentroot_owner => $documentroot_owner, + documentroot_group => $documentroot_group, + documentroot_mode => $documentroot_mode, + } + + # create vhost configuration file + apache::vhost{$name: + path => $path, + template_mode => 'perl', + vhost_mode => $vhost_mode, + vhost_source => $vhost_source, + vhost_destination => $vhost_destination, + domain => $domain, + domainalias => $domainalias, + allow_override => $allow_override, + options => $options, + additional_options => $additional_options, + cgi_binpath => $real_cgi_binpath, + ssl_mode => $ssl_mode, + htpasswd_file => $htpasswd_file, + htpasswd_path => $htpasswd_path, + mod_security => $mod_security, + } + +} |