aboutsummaryrefslogtreecommitdiff
path: root/manifests/subsystems/sysctl.pp
diff options
context:
space:
mode:
Diffstat (limited to 'manifests/subsystems/sysctl.pp')
-rw-r--r--manifests/subsystems/sysctl.pp19
1 files changed, 19 insertions, 0 deletions
diff --git a/manifests/subsystems/sysctl.pp b/manifests/subsystems/sysctl.pp
index 8c5009b..28f140b 100644
--- a/manifests/subsystems/sysctl.pp
+++ b/manifests/subsystems/sysctl.pp
@@ -42,3 +42,22 @@ class sysctl::laptop {
},
}
}
+
+class sysctl::appliance {
+ case $kernel_panic {
+ '': { $kernel_panic = "20" }
+ }
+
+ file { "/etc/sysctl.d/kernel.panic.conf":
+ owner => "root",
+ group => "root",
+ mode => 0644,
+ ensure => present,
+ content => "kernel.panic = $kernel_panic\n",
+ }
+
+ exec { "/bin/echo '$kernel_panic' > /proc/sys/kernel/panic":
+ subscribe => File["/etc/sysctl.d/kernel.panic.conf"],
+ refreshonly => true,
+ }
+}