Added support for apcupsd clients.

This commit is contained in:
Timo Mkinen 2011-03-10 22:55:34 +02:00
parent b021f1ae1c
commit 301a47af23
2 changed files with 32 additions and 0 deletions

View file

@ -13,4 +13,28 @@ class apcupsd {
require => Package["apcupsd"],
}
file { "/etc/apcupsd/apcupsd.conf":
ensure => present,
mode => 0644,
owner => "root",
group => "root",
require => Package["apcupsd"],
notify => Service["apcupsd"],
}
}
# Install APC UPS client.
#
# === Global variables
#
# $apcupsd_server:
# Server address where apcupsd server is running.
#
class apcupsd::client inherits apcupsd {
File["/etc/apcupsd/apcupsd.conf"] {
content => template("apcupsd/apcupsd.conf.client.erb"),
}
}

View file

@ -0,0 +1,8 @@
## apcupsd.conf v1.1 ##
UPSCABLE ether
UPSTYPE net
LOCKFILE /var/lock
DEVICE <%= apcupsd_server %>:3551
UPSCLASS standalone
UPSMODE disable
NETTIME 10