Commit d319da14 authored by Guillaume Abrioux's avatar Guillaume Abrioux
Browse files

update: fix ceph-crash stop task

This is a workaround for an issue in ansible.
When trying to stop/mask/disable this service in one task, the stop
didn't actually happen, the task doesn't fail but for some reason the
container is still present and running.
Then the task starting the service in the role ceph-crash fails because
it can't start the container since it's already running with the same
name.

Closes: https://bugzilla.redhat.com/show_bug.cgi?id=1955393

Signed-off-by: default avatarGuillaume Abrioux <gabrioux@redhat.com>
(cherry picked from commit 3db1ea7e)
parent 0ce27a73
...@@ -887,8 +887,14 @@ ...@@ -887,8 +887,14 @@
systemd: systemd:
name: "{{ 'ceph-crash@' + ansible_facts['hostname'] if containerized_deployment | bool else 'ceph-crash.service' }}" name: "{{ 'ceph-crash@' + ansible_facts['hostname'] if containerized_deployment | bool else 'ceph-crash.service' }}"
state: stopped state: stopped
# it needs to be done in a separate task otherwise the stop just before doesn't work.
- name: mask and disable the ceph-crash service
systemd:
name: "{{ 'ceph-crash@' + ansible_facts['hostname'] if containerized_deployment | bool else 'ceph-crash.service' }}"
enabled: no enabled: no
masked: yes masked: yes
- import_role: - import_role:
name: ceph-defaults name: ceph-defaults
- import_role: - import_role:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment