ceph_docker_image: "ceph/daemon"
ceph_docker_image_tag: latest
-# Do not comment the following variables mon_containerized_deployment_* here. These variables are being used
+# Do not comment the following variables containerized_deployment_* here. These variables are being used
# by ceph.conf.j2 template. so it should always be defined
-mon_containerized_deployment_with_kv: false
-mon_containerized_deployment: false
+containerized_deployment_with_kv: false
+containerized_deployment: false
mon_containerized_default_ceph_conf_with_kv: false
# Confiure the type of NFS gatway access. At least one must be enabled for an
+++ /dev/null
----
-# Normal case - pull image from registry
-- name: "pull {{ ceph_docker_image }} image"
- command: "docker pull {{ ceph_docker_registry}}/{{ ceph_docker_image }}:{{ ceph_docker_image_tag }}"
- changed_when: false
- when: ceph_docker_dev_image is undefined or not ceph_docker_dev_image
-
-# Dev case - export local dev image and send it across
-- name: export local ceph dev image
- local_action: command docker save -o "/tmp/{{ ceph_docker_username }}-{{ ceph_docker_imagename }}-{{ ceph_docker_image_tag }}.tar" "{{ ceph_docker_username }}/{{ ceph_docker_imagename }}:{{ ceph_docker_image_tag }}"
- when: ceph_docker_dev_image is defined and ceph_docker_dev_image
- run_once: true
-
-- name: copy ceph dev image file
- copy:
- src: "/tmp/{{ ceph_docker_username }}-{{ ceph_docker_imagename }}-{{ ceph_docker_image_tag }}.tar"
- dest: "/tmp/{{ ceph_docker_username }}-{{ ceph_docker_imagename }}-{{ ceph_docker_image_tag }}.tar"
- when: ceph_docker_dev_image is defined and ceph_docker_dev_image
-
-- name: load ceph dev image
- command: "docker load -i /tmp/{{ ceph_docker_username }}-{{ ceph_docker_imagename }}-{{ ceph_docker_image_tag }}.tar"
- when: ceph_docker_dev_image is defined and ceph_docker_dev_image
-
-- name: remove tmp ceph dev image file
- command: "rm /tmp/{{ ceph_docker_username }}-{{ ceph_docker_imagename }}-{{ ceph_docker_image_tag }}.tar"
- when: ceph_docker_dev_image is defined and ceph_docker_dev_image
when:
- rbd_client_directory_mode is not defined
or not rbd_client_directory_mode
-
become: false
always_run: true
when: generate_fsid
+
+- name: set fsid fact when generate_fsid = true
+ set_fact:
+ fsid: "{{ cluster_uuid.stdout }}"
+ when: generate_fsid
{% if ip_version == 'ipv6' %}
ms bind ipv6 = true
{% endif %}
-{% if not mon_containerized_deployment_with_kv and not mon_containerized_deployment %}
+{% if not containerized_deployment_with_kv and not containerized_deployment %}
fsid = {{ fsid }}
{% endif %}
max open files = {{ max_open_files }}
{% endfor %}
{% endif %}
-{% if not mon_containerized_deployment and not mon_containerized_deployment_with_kv %}
+{% if not containerized_deployment and not containerized_deployment_with_kv %}
{% if monitor_address_block %}
mon host = {% for host in groups[mon_group_name] %}{{ hostvars[host]['ansible_all_ipv4_addresses'] | ipaddr(monitor_address_block) | first }}{% if not loop.last %},{% endif %}{% endfor %}
{% elif groups[mon_group_name] is defined %}
{% endfor %}
{% endif %}
{% endif %}
-{% if mon_containerized_deployment %}
+{% if containerized_deployment %}
fsid = {{ fsid }}
{% if groups[mon_group_name] is defined %}
mon host = {% for host in groups[mon_group_name] %}
{% set interface = ["ansible_",ceph_mon_docker_interface]|join %}
- {% if mon_containerized_deployment -%}
+ {% if containerized_deployment -%}
{{ hostvars[host][interface]['ipv4']['address'] }}
{%- elif hostvars[host]['monitor_address'] is defined -%}
{{ hostvars[host]['monitor_address'] }}