Hi,
I see many thread of discussion on this topic, but I am not able to find any resolution on this. I want to be able to pass parameters to my handler.
I am managing a set of Redis DB on a node, and if the configuration on any of them changes, I want to be able to restart that specific instance of Redis DB. In the main task I have a loop like this
- name: Setup the redis db config file for the DBs that we are slave node
template:
src: redis.slave.conf
dest: “/etc/redis/redis.{{item.db_name}}.conf”
with_items: “{{slave_db}}”
become: yes
notify: - restart redis_server
The problem is even if one of the configurations have changed, or if a new DB is added, this results in restart of all the DB instances.
I would like to do something like - restart redis_server <db_instance>
is there any way to do something like that?
Thanks
jana