From 090486003265830ce97cbe5ae243cecc7cbbc1a7 Mon Sep 17 00:00:00 2001 From: Mike Christie Date: Wed, 12 Sep 2018 15:37:44 -0500 Subject: [PATCH] igw: stop daemons on purge all calls When purging the entire igw config (lio and rbd) stop disable the api and gw daemons. Fixes Red Hat BZ https://bugzilla.redhat.com/show_bug.cgi?id=1621255 Signed-off-by: Mike Christie --- infrastructure-playbooks/purge-iscsi-gateways.yml | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/infrastructure-playbooks/purge-iscsi-gateways.yml b/infrastructure-playbooks/purge-iscsi-gateways.yml index 369901430..8fdf2d8e1 100644 --- a/infrastructure-playbooks/purge-iscsi-gateways.yml +++ b/infrastructure-playbooks/purge-iscsi-gateways.yml @@ -35,5 +35,20 @@ igw_purge: mode="disks" when: igw_purge_type == 'all' + - name: stop and disable rbd-target-api daemon + service: + name: rbd-target-api + state: stopped + enabled: no + when: igw_purge_type == 'all' + + - name: stop and disable rbd-target-gw daemon + service: + name: rbd-target-gw + state: stopped + enabled: no + when: igw_purge_type == 'all' + - name: restart rbd-target-gw daemons service: name=rbd-target-gw state=restarted + when: igw_purge_type == 'lio' -- 2.39.5