[TIDY] Move to ansible_facts dict instead of injected variables

This commit is contained in:
Jannik Beyerstedt 2025-12-20 21:08:31 +01:00
parent d1c6d34a64
commit 1c734cefb1
15 changed files with 39 additions and 39 deletions

View file

@ -75,7 +75,7 @@
# ## If true, a field name like 'temp1_input' will be changed to 'temp_input'.
# # remove_numbers = true
{% if ansible_lsb.id is defined and ansible_lsb.id == "Raspbian" %}
{% if ansible_facts['lsb']['id'] is defined and ansible_facts['lsb']['id'] == "Raspbian" %}
# On Raspbian, get CPU temperature (in millicelsius)
[[inputs.exec]]
commands = ["cat /sys/class/thermal/thermal_zone0/temp"]