# How to target hosts in event driven ansible rulebook?

**URL:** <https://forum.ansible.com/t/how-to-target-hosts-in-event-driven-ansible-rulebook/8468>\
**Category:** Get Help\
**Tags:** ansible-rulebook, eda-server\
**Created:** [September 12, 2024, 3:47pm UTC](https://forum.ansible.com/t/how-to-target-hosts-in-event-driven-ansible-rulebook/8468 "2024-09-12T15:47:46Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![misch42](https://avatars.discourse-cdn.com/v4/letter/m/5f8ce5/32.png) [@misch42](https://forum.ansible.com/u/misch42)\
**Post date:** [September 12, 2024, 3:47pm UTC](https://forum.ansible.com/t/how-to-target-hosts-in-event-driven-ansible-rulebook/8468/1 "2024-09-12T15:47:46Z")

</div>

Hi,

I have seen the documentation of EDA. All describe a rulebook that executes a playbook that is running on the localhost. I did not find an example for a rulebook that executes a playbook on a remote host.

Any ideas? I also did not find any usable documentation for this problem.

How can I tell the eda rulebook that it need to execute a playbook for a remote host?

I have a central source-of-truth system that calls the eda with a data model of a webserver that needs to be changed. How does ansible understand that the play it to be executed on the webserver and not on the localhost?

Michael

---

<div class="post-metadata">

**Author:** ![RayJin2000](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/rayjin2000/32/3641_2.png) [@RayJin2000](https://forum.ansible.com/u/RayJin2000)\
**Post date:** [September 13, 2024, 8:07am UTC](https://forum.ansible.com/t/how-to-target-hosts-in-event-driven-ansible-rulebook/8468/2 "2024-09-13T08:07:51Z")

</div>

I haven’t heard from [Event driven Ansible](https://ansible.readthedocs.io/projects/rulebook) before, but i guess you just have to define the remote host in the `host:` section of your [Playbook](https://docs.ansible.com/ansible/latest/playbook_guide/playbooks_intro.html#playbook-execution).
