]> git.immae.eu Git - perso/Immae/Projets/Puppet.git/blobdiff - modules/profile/manifests/fstab.pp
Add monitoring for backup
[perso/Immae/Projets/Puppet.git] / modules / profile / manifests / fstab.pp
index 5f2e58e2d9a2c3a45f25c902200529c0def2df20..3af316e2808bf23afeac853ae2f69d44d1089120 100644 (file)
@@ -2,6 +2,8 @@ class profile::fstab (
   Optional[Array] $mounts = []
 ) {
   $mounts.each |$mount| {
+    ensure_packages(["parted"])
+
     unless empty($mount) {
       $infos = split($mount, ';')
 
@@ -13,6 +15,12 @@ class profile::fstab (
         device => "UUID=${infos[1]}",
         fstype => $infos[2]
       }
+
+      @profile::monitoring::local_service { "Size on ${infos[0]} partition":
+        local => {
+          check_command => "check_local_disk!10%!5%!${infos[0]}",
+        };
+      }
     }
   }
 }