From: Dimitri Savineau Date: Thu, 4 Jun 2020 20:57:17 +0000 (-0400) Subject: switch_to_container: fix osd systemd regex X-Git-Tag: v4.0.24~3 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=a165edb5ba54a498c98ba77c68153770586df13c;p=ceph-ansible.git switch_to_container: fix osd systemd regex The systemd LOAD and ACTIVE fileds could have more than one space between both values. This update the systemd regex the same way we're using it in different part of the code. Closes: https://bugzilla.redhat.com/show_bug.cgi?id=1843500 Signed-off-by: Dimitri Savineau (cherry picked from commit 50140c9b5dfd4c865b36b333db8d2f725a905a5a) --- diff --git a/infrastructure-playbooks/switch-from-non-containerized-to-containerized-ceph-daemons.yml b/infrastructure-playbooks/switch-from-non-containerized-to-containerized-ceph-daemons.yml index 38134980c..bffc4a5a2 100644 --- a/infrastructure-playbooks/switch-from-non-containerized-to-containerized-ceph-daemons.yml +++ b/infrastructure-playbooks/switch-from-non-containerized-to-containerized-ceph-daemons.yml @@ -209,7 +209,7 @@ - name: collect running osds shell: | - systemctl list-units | grep "loaded active" | grep -Eo 'ceph-osd@[0-9]+.service|ceph-volume|ceph\.target' + systemctl list-units | grep -E "loaded * active" | grep -Eo 'ceph-osd@[0-9]+.service|ceph-volume|ceph\.target' register: running_osds changed_when: false failed_when: false