27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
|
# File 'manifests/mod/userdir.pp', line 27
class apache::mod::userdir (
Optional[String[1]] $userdir = undef,
Boolean $disable_root = true,
String $path = '/home/*/public_html',
Array[String] $overrides = ['FileInfo', 'AuthConfig', 'Limit', 'Indexes'],
Array[String] $options = ['MultiViews', 'Indexes', 'SymLinksIfOwnerMatch', 'IncludesNoExec'],
Boolean $unmanaged_path = false,
Optional[String] $custom_fragment = undef,
) {
include apache
::apache::mod { 'userdir': }
$parameters = {
'disable_root' => $disable_root,
'userdir' => pick($userdir, $path),
'unmanaged_path' => $unmanaged_path,
'path' => $path,
'overrides' => $overrides,
'options' => $options,
'custom_fragment' => $custom_fragment,
}
file { 'userdir.conf':
ensure => file,
path => "${apache::mod_dir}/userdir.conf",
mode => $apache::file_mode,
content => epp('apache/mod/userdir.conf.epp', $parameters),
require => Exec["mkdir ${apache::mod_dir}"],
before => File[$apache::mod_dir],
notify => Class['apache::service'],
}
}
|