10
11
12
13
14
15
16
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
|
# File 'modules/statistics/manifests/rsyncd.pp', line 10
class statistics::rsyncd(
Array[Wmflib::Host_or_network] $hosts_allow,
) {
Class['statistics'] -> Class['statistics::rsyncd']
# this uses modules/rsync to
# set up an rsync daemon service
class { 'rsync::server':
# the default timeout of 300 is too low
timeout => 1000,
}
# Set up an rsync module
# (in /etc/rsyncd.conf) for /home.
rsync::server::module { 'home':
path => '/home',
read_only => 'yes',
list => 'yes',
uid => 'nobody',
gid => 'nogroup',
hosts_allow => $hosts_allow,
auto_firewall => true,
}
# Set up an rsync module
# (in /etc/rsyncd.conf) for /srv.
rsync::server::module { 'srv':
path => '/srv',
read_only => 'yes',
list => 'yes',
uid => 'nobody',
gid => 'nogroup',
hosts_allow => $hosts_allow,
auto_firewall => true,
}
profile::auto_restarts::service { 'rsync': }
}
|