--- - name: Reboot a machine hosts: all become: yes tasks: - name: Reboot the machine ansible.builtin.reboot: msg: "Reboot avec ansible" connect_timeout: 5 reboot_timeout: 600 pre_reboot_delay: 0 post_reboot_delay: 30