]> git.apps.os.sepia.ceph.com Git - ceph-ansible.git/commit
ceph-handler: don't restart all OSDs with limit
authorDimitri Savineau <dsavinea@redhat.com>
Wed, 2 Oct 2019 18:48:53 +0000 (14:48 -0400)
committerGuillaume Abrioux <gabrioux@redhat.com>
Fri, 4 Oct 2019 05:42:58 +0000 (07:42 +0200)
commit8ec632c42c8ec9db10196d6ac6aca40caa462b91
treeb92e4e284484f0dfde124a2e6839578abe95c10d
parent70267cb30bb627ec1b820dcda33ca5354d8569cb
ceph-handler: don't restart all OSDs with limit

When using the ansible --limit option on one or few OSD nodes and if the
handler is triggered then we will restart the OSD service on all OSDs
nodes instead of the hosts limited by the limit value.
Even if the play is limited by the --limit value we are using all OSD
nodes from the OSD group.

  with_items: '{{ groups[osd_group_name] }}'

Instead we should iterate only on the nodes present in both OSD group and
limit list.

Signed-off-by: Dimitri Savineau <dsavinea@redhat.com>
(cherry picked from commit 0346871fb5c46fb1fedfb24ffe5a8c02108c244e)
roles/ceph-handler/handlers/main.yml