mirror of https://github.com/ceph/ceph-ansible.git
docker2podman: skip some role imports from handler
when running docker-to-podman playbook, there's no need to call
`ceph-config` and `ceph-rgw` from the role `ceph-handler`.
It can even have side effects when coming from a baremetal cluster that
was previously migrated using the switch-to-containers playbook. Indeed
it might complain about missing .target systemd unit since they are
removed during that migration.
Closes: https://bugzilla.redhat.com/show_bug.cgi?id=1944999
Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com>
(cherry picked from commit 70f19be367
)
pull/6453/head
v4.0.52
parent
c0c90c6747
commit
3ef9690cd1
|
@ -65,6 +65,11 @@
|
||||||
gather_facts: false
|
gather_facts: false
|
||||||
become: true
|
become: true
|
||||||
tasks:
|
tasks:
|
||||||
|
- name: set_fact docker2podman and container_binary
|
||||||
|
set_fact:
|
||||||
|
docker2podman: True
|
||||||
|
container_binary: podman
|
||||||
|
|
||||||
- import_role:
|
- import_role:
|
||||||
name: ceph-defaults
|
name: ceph-defaults
|
||||||
- import_role:
|
- import_role:
|
||||||
|
@ -72,11 +77,6 @@
|
||||||
- import_role:
|
- import_role:
|
||||||
name: ceph-handler
|
name: ceph-handler
|
||||||
|
|
||||||
- name: set_fact docker2podman and container_binary
|
|
||||||
set_fact:
|
|
||||||
docker2podman: True
|
|
||||||
container_binary: podman
|
|
||||||
|
|
||||||
- name: install podman
|
- name: install podman
|
||||||
package:
|
package:
|
||||||
name: podman
|
name: podman
|
||||||
|
|
|
@ -7,3 +7,4 @@
|
||||||
- name: set_fact container_binary
|
- name: set_fact container_binary
|
||||||
set_fact:
|
set_fact:
|
||||||
container_binary: "{{ 'podman' if (podman_binary.stat.exists and ansible_facts['distribution'] == 'Fedora') or (ansible_facts['os_family'] == 'RedHat' and ansible_facts['distribution_major_version'] == '8') else 'docker' }}"
|
container_binary: "{{ 'podman' if (podman_binary.stat.exists and ansible_facts['distribution'] == 'Fedora') or (ansible_facts['os_family'] == 'RedHat' and ansible_facts['distribution_major_version'] == '8') else 'docker' }}"
|
||||||
|
when: not docker2podman | default(false) | bool
|
|
@ -51,6 +51,7 @@
|
||||||
|
|
||||||
- name: rgw multi-instances related tasks
|
- name: rgw multi-instances related tasks
|
||||||
when:
|
when:
|
||||||
|
- not docker2podman | default(false) | bool
|
||||||
- inventory_hostname in groups.get(rgw_group_name, [])
|
- inventory_hostname in groups.get(rgw_group_name, [])
|
||||||
- handler_rgw_status | bool
|
- handler_rgw_status | bool
|
||||||
block:
|
block:
|
||||||
|
|
Loading…
Reference in New Issue