- name: Install iperf3 service
  hosts: yellow
  vars_files:
    - vars.yaml
  tasks:
  - name: Ensure iperf3 is installed
    ansible.builtin.dnf:
      name:
        - iperf3
      state: present
  - name: Copy iperf3.service
    template:
      src: iperf3.service
      dest: /etc/systemd/system/iperf3.service
      owner: root
      group: root
      mode: '0644'
  - name: Reload iperf3 timer
    ansible.builtin.systemd_service:
      state: restarted
      name: iperf3.service
      enabled: true
