1
2
3
4
5
6
7
8
9
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
48
49
50
51
52
53
54
55
56
57
|
class s6::install {
package {
's6':
ensure => installed,
;
}
file {
'/etc/s6-services/':
ensure => directory,
;
'/etc/s6-scandir/':
ensure => directory,
;
'/var/log/s6/':
ensure => directory,
;
}
if $facts['service_provider'] == 'systemd' {
file {
'/etc/systemd/system/s6.service':
ensure => present,
source => 'puppet:///modules/s6/etc/systemd/system/s6.service',
require => Package['s6'],
notify => Class['s6::service'],
;
}
} else {
file {
'/usr/local/bin/s6-svscanboot':
ensure => present,
source => [
"puppet:///modules/s6/usr/local/bin/s6-svscanboot.${facts['os']['distro']['codename']}",
'puppet:///modules/s6/usr/local/bin/s6-svscanboot',
],
mode => '0755',
require => Package['s6'],
notify => Class['s6::service'],
;
'/etc/init.d/s6':
ensure => present,
source => 'puppet:///modules/s6/etc/init.d/s6',
mode => '0755',
require => Package['s6'],
notify => Class['s6::service'],
;
}
}
user {
's6-logs':
ensure => present,
home => '/nonexistant',
shell => '/usr/sbin/nologin',
system => true,
;
}
}
|