cd519db139
In the current deployment of ceph, the node name of osd and the name of mon are both IP, and other daemons use hostname. This commit adds support for naming mon and osd nodes using hostname, and does not change the default ip-named way. Change-Id: I22bef72dcd8fc8bcd391ae30e4643520250fd556
67 lines
3.2 KiB
Django/Jinja
67 lines
3.2 KiB
Django/Jinja
[global]
|
|
log file = /var/log/kolla/ceph/$cluster-$name.log
|
|
log to syslog = false
|
|
err to syslog = false
|
|
log to stderr = false
|
|
err to stderr = false
|
|
|
|
fsid = {{ ceph_cluster_fsid }}
|
|
{% if ceph_mon_host_type == 'HOSTNAME' %}
|
|
mon initial members = {% for host in groups['ceph-mon'] %}{{ hostvars[host]['ansible_hostname'] }}{% if not loop.last %}, {% endif %}{% endfor %}
|
|
{% elif ceph_mon_host_type == 'FQDN' %}
|
|
mon initial members = {% for host in groups['ceph-mon'] %}{{ hostvars[host]['ansible_fqdn'] }}{% if not loop.last %}, {% endif %}{% endfor %}
|
|
{% elif ceph_mon_host_type == 'INVENTORY' %}
|
|
mon initial members = {% for host in groups['ceph-mon'] %}{{ host }}{% if not loop.last %}, {% endif %}{% endfor %}
|
|
{%- else %}
|
|
mon initial members = {% for host in groups['ceph-mon'] %}{{ hostvars[host]['ansible_' + hostvars[host]['storage_interface']]['ipv4']['address'] }}{% if not loop.last %}, {% endif %}{% endfor %}
|
|
{% endif %}
|
|
|
|
mon host = {% for host in groups['ceph-mon'] %}{{ hostvars[host]['ansible_' + hostvars[host]['storage_interface']]['ipv4']['address'] }}{% if not loop.last %}, {% endif %}{% endfor %}
|
|
|
|
mon addr = {% for host in groups['ceph-mon'] %}{{ hostvars[host]['ansible_' + hostvars[host]['storage_interface']]['ipv4']['address'] }}:6789{% if not loop.last %}, {% endif %}{% endfor %}
|
|
|
|
auth cluster required = cephx
|
|
auth service required = cephx
|
|
auth client required = cephx
|
|
|
|
# NOTE(inc0): This line will mean that if ceph was upgraded, it will run as root
|
|
# until contents of /var/lib/ceph are chowned to ceph user.
|
|
# This change was introduced in Jewel version and we should include
|
|
# chown operation in upgrade procedure. https://bugs.launchpad.net/kolla/+bug/1620702
|
|
setuser match path = /var/lib/ceph/$type/$cluster-$id
|
|
|
|
# NOTE(Jeffrey4l): kolla is using node ip as host bucket name, whereas `osd
|
|
# crush update on start` feature depends on hostname. Disable this feature for
|
|
# less confusion and upgrade impact.
|
|
osd crush update on start = false
|
|
|
|
[mon]
|
|
# NOTE(SamYaple): The monitor files have been known to grow very large. The
|
|
# only fix for that is to compact the files.
|
|
mon compact on start = true
|
|
mon cluster log file = /var/log/kolla/ceph/$cluster.log
|
|
|
|
{% if service_name is defined and service_name == 'ceph-rgw' %}
|
|
[client.radosgw.gateway]
|
|
host = {{ hostvars[inventory_hostname]['ansible_' + storage_interface]['ipv4']['address'] }}
|
|
rgw frontends = civetweb port={{ api_interface_address }}:{{ rgw_port }}
|
|
{% if enable_ceph_rgw_keystone | bool %}
|
|
rgw_keystone_url = {{ keystone_admin_url }}
|
|
rgw_keystone_admin_user = {{ ceph_rgw_keystone_user }}
|
|
rgw_keystone_admin_password = {{ ceph_rgw_keystone_password }}
|
|
rgw_keystone_admin_project = service
|
|
rgw_keystone_admin_domain = default
|
|
rgw_keystone_api_version = 3
|
|
rgw_keystone_accepted_roles = admin, {{ keystone_default_user_role }}
|
|
rgw_keystone_accepted_admin_roles = ResellerAdmin
|
|
rgw_swift_versioning_enabled = true
|
|
{% endif %}
|
|
keyring = /etc/ceph/ceph.client.radosgw.keyring
|
|
log file = /var/log/kolla/ceph/client.radosgw.gateway.log
|
|
{% if ceph_rgw_compatibility | bool %}
|
|
rgw_swift_url_prefix = "/"
|
|
rgw_enable_apis = swift,swift_auth,admin
|
|
rgw_swift_enforce_content_length = true
|
|
{% endif %}
|
|
{% endif %}
|