[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

@ -14,12 +14,12 @@
state: present
- name: Telegraf - Add telegraf repo
become: true
when: ansible_distribution_release != 'bookworm'
when: ansible_facts['distribution_release'] != 'bookworm'
ansible.builtin.apt_repository:
repo: "deb https://repos.influxdata.com/debian {{ ansible_distribution_release }} stable"
repo: "deb https://repos.influxdata.com/debian {{ ansible_facts['distribution_release'] }} stable"
state: present
- name: Telegraf - Add telegraf repo
when: ansible_distribution_release == 'bookworm'
when: ansible_facts['distribution_release'] == 'bookworm'
become: true
ansible.builtin.apt_repository:
repo: "deb https://repos.influxdata.com/debian bullseye stable"