44 lines
1.9 KiB
YAML
44 lines
1.9 KiB
YAML
---
|
|
# Copyright 2021 Red Hat, Inc.
|
|
# All Rights Reserved.
|
|
#
|
|
# Licensed under the Apache License, Version 2.0 (the "License"); you may
|
|
# not use this file except in compliance with the License. You may obtain
|
|
# a copy of the License at
|
|
#
|
|
# http://www.apache.org/licenses/LICENSE-2.0
|
|
#
|
|
# Unless required by applicable law or agreed to in writing, software
|
|
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
|
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
|
# License for the specific language governing permissions and limitations
|
|
# under the License.
|
|
|
|
- name: Set ceph CLI
|
|
set_fact:
|
|
tripleo_cephadm_ceph_cli: >-
|
|
{{ tripleo_cephadm_container_cli }} run --rm {{ tripleo_cephadm_container_options }}
|
|
{% if mount_certs|default(false) %}
|
|
--volume {{ tripleo_cephadm_certs }}:/etc/pki/tls:z
|
|
{% endif %}
|
|
{% if sensitive_data|default(false) %}
|
|
--interactive
|
|
{% endif %}
|
|
--volume {{ tripleo_cephadm_config_home }}:/etc/ceph:z
|
|
{% if mount_spec|default(false) %}
|
|
--volume {{ tripleo_cephadm_spec }}:{{ tripleo_cephadm_container_spec }}:z
|
|
{% endif %}
|
|
{% if admin_daemon|default(false) %}
|
|
--volume /var/run/ceph/{{ tripleo_cephadm_fsid }}:/var/run/ceph:z
|
|
{% endif %}
|
|
--entrypoint {{ ceph_command | default('ceph') }}
|
|
{{ tripleo_cephadm_container_ns }}/{{ tripleo_cephadm_container_image }}:{{ tripleo_cephadm_container_tag }}
|
|
{% if ceph_command|default('ceph') == 'ceph' or ceph_command|default('ceph') == 'rados' -%}
|
|
{% if not admin_daemon|default(false) -%}
|
|
--fsid {{ tripleo_cephadm_fsid }} -c {{ tripleo_cephadm_conf }} -k {{ tripleo_cephadm_keyring_prefix }}.{{ select_keyring| default('admin') }}.keyring
|
|
{%- endif %}
|
|
{% if external_cluster|default(false) -%}
|
|
-n client.{{ select_keyring }}
|
|
{%- endif %}
|
|
{%- endif %}
|