--- - name: include system_checks.yml include_tasks: system_checks.yml - name: include check_mandatory_vars.yml include_tasks: check_mandatory_vars.yml - name: include pre_requisites/prerequisites.yml include_tasks: pre_requisites/prerequisites.yml when: - not is_atomic # NOTE(guits): would be nice to refact this block with L39-45 in roles/ceph-common/tasks/facts.yml - name: set_fact monitor_name ansible_hostname set_fact: monitor_name: "{{ ansible_hostname }}" when: - not mon_use_fqdn - name: set_fact monitor_name ansible_fqdn set_fact: monitor_name: "{{ ansible_fqdn }}" when: - mon_use_fqdn - name: get docker version command: docker --version changed_when: false check_mode: no register: ceph_docker_version - name: set_fact ceph_docker_version ceph_docker_version.stdout.split set_fact: ceph_docker_version: "{{ ceph_docker_version.stdout.split(' ')[2] }}" # Only include 'checks.yml' when : # we are deploying containers without kv AND host is either a mon OR a nfs OR an osd, # AND # a cluster is not already running, # AND # we are not playing rolling-update.yml playbook. - name: check if a cluster is already running command: "docker ps -q --filter='name=ceph-mon-{{ ansible_hostname }}'" register: ceph_health changed_when: false failed_when: false check_mode: no - name: include checks.yml include_tasks: checks.yml when: - (not containerized_deployment_with_kv and ((inventory_hostname in groups.get(mon_group_name, [])) or (inventory_hostname in groups.get(nfs_group_name, [])) or (inventory_hostname in groups.get(osd_group_name, [])))) - ceph_health.stdout_lines | length == 0 - not rolling_update | default(false) - name: include misc/ntp_atomic.yml include_tasks: misc/ntp_atomic.yml when: - is_atomic - ansible_os_family == 'RedHat' - ntp_service_enabled - name: include misc/ntp_rpm.yml include_tasks: misc/ntp_rpm.yml when: - not is_atomic - ansible_os_family in ['RedHat', 'Suse'] - ntp_service_enabled - name: include misc/ntp_debian.yml include_tasks: misc/ntp_debian.yml when: - ansible_os_family == 'Debian' - ntp_service_enabled - name: include fetch_image.yml include_tasks: fetch_image.yml tags: - fetch_container_image - name: get ceph version command: docker run --rm --entrypoint /usr/bin/ceph {{ ceph_client_docker_registry}}/{{ ceph_client_docker_image }}:{{ ceph_client_docker_image_tag }} --version changed_when: false check_mode: no register: ceph_version - name: set_fact ceph_version ceph_version.stdout.split set_fact: ceph_version: "{{ ceph_version.stdout.split(' ')[2] }}" - name: include release.yml include_tasks: release.yml # NOTE (jimcurtis): dirs_permissions.yml must precede fetch_configs.yml # # because it creates the directories needed by the latter. - name: include dirs_permissions.yml include_tasks: dirs_permissions.yml