Execut playbook host after host

Hi all,

I have my principal playbook with this content :

  • hosts: all
    become: no
    gather_facts: no
    roles:
  • role

I have on file with content :

my_host_1 ansible_user: my_user

my_host_2 ansible_user: my_user

I want that when i run my task, ansible execute only on my_host_1
and when ansible fish execut task, he execut in second host of my inventory “my_host_2”

Someone have an idea please ?

Thanks community Ansible !!! :wink:

Regards,