aboutsummaryrefslogtreecommitdiff
path: root/manifests
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2010-01-03 15:11:54 -0200
committerSilvio Rhatto <rhatto@riseup.net>2010-01-03 15:11:54 -0200
commit511d6a71ad01d75629bdd4ed5150d7cf41b20235 (patch)
treef78a8e7ac0df0ec4cf74732391de58f8e1f89977 /manifests
parentf2a4c51c5368f18b4f34d46688fcaf0fe5c7cdf0 (diff)
downloadpuppet-nodo-511d6a71ad01d75629bdd4ed5150d7cf41b20235.tar.gz
puppet-nodo-511d6a71ad01d75629bdd4ed5150d7cf41b20235.tar.bz2
Adding UPS configuration
Diffstat (limited to 'manifests')
-rw-r--r--manifests/init.pp2
-rw-r--r--manifests/ups.pp13
2 files changed, 15 insertions, 0 deletions
diff --git a/manifests/init.pp b/manifests/init.pp
index 76ef58d..cde0182 100644
--- a/manifests/init.pp
+++ b/manifests/init.pp
@@ -9,6 +9,7 @@ import "lsb.pp"
import "motd.pp"
import "sudo.pp"
import "sysctl.pp"
+import "ups.pp"
class nodo {
include lsb
@@ -73,6 +74,7 @@ class nodo::server inherits nodo {
include initramfs
include firewire
include sysctl
+ include ups
# DNS resolver
$resolvconf_domain = "$domain"
diff --git a/manifests/ups.pp b/manifests/ups.pp
new file mode 100644
index 0000000..8f7eaf7
--- /dev/null
+++ b/manifests/ups.pp
@@ -0,0 +1,13 @@
+class ups {
+ include apcupsd
+
+ case $has_ups {
+ true: {
+ apcupsd:ups { "ups0"
+ type => 'usb',
+ cable => 'usb',
+ device => '/dev/usb/hiddev0',
+ }
+ }
+ }
+}