From cae876174a608f38565f40e2339bb1013616fa7c Mon Sep 17 00:00:00 2001 From: Silvio Rhatto Date: Fri, 5 Jul 2024 12:57:18 -0300 Subject: Fix: nodo::subsystem::sensors: move hddtemp portion to the bottom --- manifests/subsystem/sensors.pp | 30 ++++++++++++++++-------------- 1 file changed, 16 insertions(+), 14 deletions(-) diff --git a/manifests/subsystem/sensors.pp b/manifests/subsystem/sensors.pp index 473def3..8a19831 100644 --- a/manifests/subsystem/sensors.pp +++ b/manifests/subsystem/sensors.pp @@ -21,6 +21,22 @@ class nodo::subsystem::sensors { ensure => $lm_sensors, } + # + # drivetemp + # + # Just load this driver and lm-sensors will detect sensors automatically. + # + # https://www.baeldung.com/linux/hdd-ssd-temperature + # https://askubuntu.com/questions/1426482/tool-to-monitor-hdd-temperature-in-ubuntu-server-22-04 + # https://wiki.archlinux.org/title/Lm_sensors#S.M.A.R.T._drive_temperature + # https://github.com/philipl/drivetemp + + $drivetemp = lookup('nodo::sensors::drivetemp', undef, undef, 'present') + + nodo::subsystem::modprobe::module { 'drivetemp': + ensure => $drivetemp, + } + # # hddtemp # @@ -37,18 +53,4 @@ class nodo::subsystem::sensors { default => absent, } } - - # - # drivetemp - # - # https://www.baeldung.com/linux/hdd-ssd-temperature - # https://askubuntu.com/questions/1426482/tool-to-monitor-hdd-temperature-in-ubuntu-server-22-04 - # https://wiki.archlinux.org/title/Lm_sensors#S.M.A.R.T._drive_temperature - # https://github.com/philipl/drivetemp - - $drivetemp = lookup('nodo::sensors::drivetemp', undef, undef, 'present') - - nodo::subsystem::modprobe::module { 'drivetemp': - ensure => $drivetemp, - } } -- cgit v1.2.3