]> git.immae.eu Git - perso/Immae/Projets/Puppet.git/blob - modules/profile/manifests/fstab.pp
Add monitoring for backup
[perso/Immae/Projets/Puppet.git] / modules / profile / manifests / fstab.pp
1 class profile::fstab (
2 Optional[Array] $mounts = []
3 ) {
4 $mounts.each |$mount| {
5 ensure_packages(["parted"])
6
7 unless empty($mount) {
8 $infos = split($mount, ';')
9
10 file { $infos[0]:
11 ensure => directory,
12 } ->
13 mount { $infos[0]:
14 ensure => mounted,
15 device => "UUID=${infos[1]}",
16 fstype => $infos[2]
17 }
18
19 @profile::monitoring::local_service { "Size on ${infos[0]} partition":
20 local => {
21 check_command => "check_local_disk!10%!5%!${infos[0]}",
22 };
23 }
24 }
25 }
26 }