]> git.apps.os.sepia.ceph.com Git - ceph-ansible.git/commitdiff
ceph-mon: Bind mount the ca-trust directory
authorDimitri Savineau <dsavinea@redhat.com>
Mon, 26 Aug 2019 14:47:05 +0000 (10:47 -0400)
committerDimitri Savineau <savineau.dimitri@gmail.com>
Wed, 28 Aug 2019 13:44:34 +0000 (09:44 -0400)
On containerized deployment, the mon container sometimes needs to
access to the radosgw endpoint (via the radosgw-admin command). When
using TLS on the radosgw with self-signed certificates then we need to
access to the CA certification from the mon container.
The CA certificate needs to be added on the host and then the directory
will be bind mount on the container.

Resolves: #4358

Signed-off-by: Dimitri Savineau <dsavinea@redhat.com>
(cherry picked from commit 2b0616ecca1f526dd669d00b7b5f501affebb6ca)

roles/ceph-mon/templates/ceph-mon.service.j2

index 28db4493ec270f7c16bbf4b5a5802e25a85e6216..68f7b587dec7072e623ac76c70fdd454530fe016 100644 (file)
@@ -22,6 +22,9 @@ ExecStart=/usr/bin/{{ container_binary }} run --rm --name ceph-mon-%i \
   -v /var/run/ceph:/var/run/ceph:z \
   -v /etc/localtime:/etc/localtime:ro \
   -v /var/log/ceph:/var/log/ceph:z \
+{% if ansible_distribution == 'RedHat' -%}
+  -v /etc/pki/ca-trust/extracted:/etc/pki/ca-trust/extracted:z \
+{% endif -%}
 {% if mon_docker_privileged -%}
   --privileged \
 {% endif -%}