From ffb1e2bcd691fe3d1d3d66836cc2faa8cbcc1b65 Mon Sep 17 00:00:00 2001 From: Conrad Kostecki Date: Sat, 1 Jun 2013 00:12:38 +0200 Subject: Thermal Plugin added --- plugin/thermal.php | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 plugin/thermal.php diff --git a/plugin/thermal.php b/plugin/thermal.php new file mode 100644 index 0000000..eaef5e8 --- /dev/null +++ b/plugin/thermal.php @@ -0,0 +1,26 @@ +ds_names = array( + 'value' => 'Value', +); +switch($obj->args['type']) { + case 'gauge': + $obj->rrd_title = sprintf('Temperature (%s)', $obj->args['pinstance']); + $obj->rrd_vertical = '°C'; + $obj->rrd_format = '%.1lf'; + break; +} + +collectd_flush($obj->identifiers); +$obj->rrd_graph(); -- cgit v1.1