diff --git a/bundles/grafana/dashboard-rows/sensors.py b/bundles/grafana/dashboard-rows/sensors.py index 4243eae..f6d8b96 100644 --- a/bundles/grafana/dashboard-rows/sensors.py +++ b/bundles/grafana/dashboard-rows/sensors.py @@ -3,7 +3,7 @@ def dashboard_row_sensors(panel_id, node): 'title': 'sensors', 'collapse': False, 'editable': False, - 'height': '200px', + 'height': '250px', 'panels': [ { 'aliasColors': {}, @@ -13,11 +13,11 @@ def dashboard_row_sensors(panel_id, node): 'datasource': None, 'fieldConfig': { 'defaults': { - 'displayName': '${__field.labels.feature}' + 'displayName': '${__field.labels.chip} ${__field.labels.feature}' }, 'overrides': [] }, - 'fill': 1, + 'fill': 0, 'fillGradient': 0, 'hiddenSeries': False, 'id': next(panel_id), @@ -33,7 +33,7 @@ def dashboard_row_sensors(panel_id, node): 'values': False }, 'lines': True, - 'linewidth': 1, + 'linewidth': 2, 'NonePointMode': 'None', 'options': { 'alertThreshold': True @@ -60,7 +60,6 @@ def dashboard_row_sensors(panel_id, node): |> range(start: v.timeRangeStart, stop: v.timeRangeStop) |> filter(fn: (r) => r["_measurement"] == "sensors" and - r["chip"] == "coretemp-isa-0000" and r["_field"] == "temp_input" and r["host"] == "{node.name}" ) @@ -76,7 +75,7 @@ def dashboard_row_sensors(panel_id, node): ], 'thresholds': [], 'timeRegions': [], - 'title': 'CPU Temperature', + 'title': 'temperatures', 'tooltip': { 'shared': True, 'sort': 0, @@ -121,11 +120,11 @@ def dashboard_row_sensors(panel_id, node): 'datasource': None, 'fieldConfig': { 'defaults': { - 'displayName': '${__field.labels.feature}' + 'displayName': '${__field.labels.chip} ${__field.labels.feature}' }, 'overrides': [] }, - 'fill': 1, + 'fill': 0, 'fillGradient': 0, 'hiddenSeries': False, 'id': next(panel_id), @@ -141,7 +140,7 @@ def dashboard_row_sensors(panel_id, node): 'values': False }, 'lines': True, - 'linewidth': 1, + 'linewidth': 2, 'NonePointMode': 'None', 'options': { 'alertThreshold': True @@ -183,7 +182,7 @@ def dashboard_row_sensors(panel_id, node): ], 'thresholds': [], 'timeRegions': [], - 'title': 'Fan speed', + 'title': 'fans', 'tooltip': { 'shared': True, 'sort': 0, diff --git a/bundles/grafana/items.py b/bundles/grafana/items.py index ed98eb3..d65f555 100644 --- a/bundles/grafana/items.py +++ b/bundles/grafana/items.py @@ -101,9 +101,9 @@ for rnode in repo.nodes: ], } - if rnode.has_bundle('pacman'): + if rnode.has_bundle('lm-sensors'): dashboard['rows'].append(dashboard_row_sensors(panel_id, rnode)) - dashboard['tags'].add('lm_sensors') + dashboard['tags'].add('lm-sensors') dashboard['rows'].append(dashboard_row_disk_space(panel_id, rnode)) dashboard['rows'].append(dashboard_row_disk_iops(panel_id, rnode)) diff --git a/bundles/pacman/metadata.py b/bundles/lm-sensors/metadata.py similarity index 54% rename from bundles/pacman/metadata.py rename to bundles/lm-sensors/metadata.py index f69d895..ffd3900 100644 --- a/bundles/pacman/metadata.py +++ b/bundles/lm-sensors/metadata.py @@ -1,4 +1,14 @@ defaults = { + 'apt': { + 'packages': { + 'lm-sensors': {}, + }, + }, + 'pacman': { + 'packages': { + 'lm_sensors': {}, + }, + }, 'telegraf': { 'input_plugins': { 'builtin': { diff --git a/bundles/pacman/items.py b/bundles/pacman/items.py index 8bf795f..eafc89c 100644 --- a/bundles/pacman/items.py +++ b/bundles/pacman/items.py @@ -77,7 +77,6 @@ if node.metadata.get('pacman/install_gui', False): 'rfkill': {}, 'wpa_supplicant': {}, 'wpa_actiond': {}, - 'lm_sensors': {}, } for pkg, config in node.metadata.get('pacman/packages', {}).items(): diff --git a/nodes/home/kodi-wohnzimmer.py b/nodes/home/kodi-wohnzimmer.py index 8d92f12..cfb651a 100644 --- a/nodes/home/kodi-wohnzimmer.py +++ b/nodes/home/kodi-wohnzimmer.py @@ -1,6 +1,7 @@ nodes['home.kodi-wohnzimmer'] = { 'hostname': '172.19.138.24', 'bundles': { + 'lm-sensors', 'kodi', 'nfs-client', 'smartd', diff --git a/nodes/home/nas.py b/nodes/home/nas.py index cb182bb..007b9cf 100644 --- a/nodes/home/nas.py +++ b/nodes/home/nas.py @@ -4,6 +4,7 @@ nodes['home.nas'] = { 'hostname': '172.19.138.20', 'bundles': { 'backup-server', + 'lm-sensors', 'mosquitto', 'netdata', 'nfs-server', diff --git a/nodes/htz/ex42-1048908.py b/nodes/htz/ex42-1048908.py index 61c238d..b01c119 100644 --- a/nodes/htz/ex42-1048908.py +++ b/nodes/htz/ex42-1048908.py @@ -4,6 +4,7 @@ nodes['htz.ex42-1048908'] = { 'element-web', 'gitea', 'jenkins-ci', + 'lm-sensors', 'matrix-media-repo', 'matrix-synapse', 'mautrix-telegram', diff --git a/nodes/kunsi-seibert-x1.py b/nodes/kunsi-seibert-x1.py index 0ba6904..68740e7 100644 --- a/nodes/kunsi-seibert-x1.py +++ b/nodes/kunsi-seibert-x1.py @@ -5,6 +5,7 @@ nodes['kunsi-seibert-x1'] = { 'bundles': { 'basic', 'lldp', + 'lm-sensors', 'nfs-client', 'pacman', 'openssh', diff --git a/nodes/kunsi-t470.py b/nodes/kunsi-t470.py index 9555c3a..fef62ad 100644 --- a/nodes/kunsi-t470.py +++ b/nodes/kunsi-t470.py @@ -4,6 +4,7 @@ nodes['kunsi-t470'] = { 'hostname': 'localhost', 'bundles': { 'lldp', + 'lm-sensors', 'nfs-client', }, 'groups': { diff --git a/nodes/rx300.py b/nodes/rx300.py index d75728e..1e52908 100644 --- a/nodes/rx300.py +++ b/nodes/rx300.py @@ -10,6 +10,7 @@ nodes['rx300'] = { 'hostname': '172.19.138.26', 'bundles': { 'lldp', # TODO remove once this is no longer at home + 'lm-sensors', 'smartd', 'vmhost', 'zfs',