17
18
19
20
21
22
23
24
25
26
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
60
61
|
# File 'manifests/server/service.pp', line 17
class nfs::server::service {
if $::nfs::nfs_v4 == true {
if $::nfs::server_nfsv4_servicehelper != undef and $::nfs::manage_server_servicehelper {
$server_service_require = Service[$::nfs::server_nfsv4_servicehelper]
$::nfs::server_nfsv4_servicehelper.each |$service_name| {
service { $service_name:
ensure => $::nfs::server_service_ensure,
enable => $::nfs::server_service_enable,
hasrestart => $::nfs::server_service_hasrestart,
hasstatus => $::nfs::server_service_hasstatus,
subscribe => [ Concat[$::nfs::exports_file], Augeas[$::nfs::idmapd_file] ],
}
}
} else {
$server_service_require = undef
}
if $::nfs::manage_server_service {
service { $::nfs::server_service_name:
ensure => $::nfs::server_service_ensure,
enable => $::nfs::server_service_enable,
hasrestart => $::nfs::server_service_hasrestart,
hasstatus => $::nfs::server_service_hasstatus,
restart => $::nfs::server_service_restart_cmd,
subscribe => [ Concat_File[$::nfs::exports_file], Augeas[$::nfs::idmapd_file] ],
require => $server_service_require,
}
}
} else {
if $::nfs::manage_server_service {
service { $::nfs::server_service_name:
ensure => $::nfs::server_service_ensure,
enable => $::nfs::server_service_enable,
hasrestart => $::nfs::server_service_hasrestart,
hasstatus => $::nfs::server_service_hasstatus,
restart => $::nfs::server_service_restart_cmd,
subscribe => Concat_File[$::nfs::exports_file],
}
}
}
}
|