Common: Add profiles

Remove `rgw enable static website` and `rgw enable usage log` from
ceph.conf and make it usable with ceph_config_overrides as profiles.

Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com>
pull/1018/head
Guillaume Abrioux 2017-06-02 10:10:03 +02:00
parent 894df4b8c8
commit 233696d1b1
5 changed files with 28 additions and 13 deletions

View File

@ -2,7 +2,7 @@
# THIS FILE IS AN EXAMPLE THAT CONTAINS A SET OF VARIABLE FOR A PARTICULAR PURPOSE # THIS FILE IS AN EXAMPLE THAT CONTAINS A SET OF VARIABLE FOR A PARTICULAR PURPOSE
# GOAL: CONFIGURE RADOS GATEWAY WITH KEYSTONE V2 # GOAL: CONFIGURE RADOS GATEWAY WITH KEYSTONE V2
# #
# The following variables should be added in your group_vars/rgws file # The following variables should be added in your group_vars/rgws.yml file
# The double quotes are important, do NOT remove them. # The double quotes are important, do NOT remove them.

View File

@ -2,7 +2,7 @@
# THIS FILE IS AN EXAMPLE THAT CONTAINS A SET OF VARIABLE FOR A PARTICULAR PURPOSE # THIS FILE IS AN EXAMPLE THAT CONTAINS A SET OF VARIABLE FOR A PARTICULAR PURPOSE
# GOAL: CONFIGURE RADOS GATEWAY WITH KEYSTONE V3 # GOAL: CONFIGURE RADOS GATEWAY WITH KEYSTONE V3
# #
# The following variables should be added in your group_vars/rgws file # The following variables should be added in your group_vars/rgws.yml file
# The double quotes are important, do NOT remove them. # The double quotes are important, do NOT remove them.

View File

@ -0,0 +1,11 @@
---
# THIS FILE IS AN EXAMPLE THAT CONTAINS A SET OF VARIABLE FOR A PARTICULAR PURPOSE
# GOAL: CONFIGURE RADOS GATEWAY WITH STATIC WEBSITE
#
# The following variables should be added in your group_vars/rgws.yml file
# The double quotes are important, do NOT remove them.
ceph_conf_overrides:
"client.rgw.{{ hostvars[inventory_hostname]['ansible_hostname'] }}":
rgw enable static website = true
rgw dns s3website name = objects-website-region.domain.com

View File

@ -0,0 +1,15 @@
---
# THIS FILE IS AN EXAMPLE THAT CONTAINS A SET OF VARIABLE FOR A PARTICULAR PURPOSE
# GOAL: CONFIGURE RADOS GATEWAY WITH USAGE LOG
#
# The following variables should be added in your group_vars/rgws.yml file
# The double quotes are important, do NOT remove them.
ceph_conf_overrides:
"client.rgw.{{ hostvars[inventory_hostname]['ansible_hostname'] }}":
rgw enable usage log = true
rgw usage log tick interval = 30
rgw usage log flush threshold = 1024
rgw usage max shards = 32
rgw usage max user shards = 1

View File

@ -134,17 +134,6 @@ log file = /var/log/ceph/{{ cluster }}-rgw-{{ hostvars[host]['ansible_hostname']
rgw data = /var/lib/ceph/radosgw/{{ cluster }}-rgw.{{ hostvars[host]['ansible_hostname'] }} rgw data = /var/lib/ceph/radosgw/{{ cluster }}-rgw.{{ hostvars[host]['ansible_hostname'] }}
rgw frontends = civetweb port={{ radosgw_civetweb_bind_ip }}:{{ radosgw_civetweb_port }} num_threads={{ radosgw_civetweb_num_threads }} rgw frontends = civetweb port={{ radosgw_civetweb_bind_ip }}:{{ radosgw_civetweb_port }} num_threads={{ radosgw_civetweb_num_threads }}
{% endif %} {% endif %}
{% if radosgw_usage_log | bool %}
rgw enable usage log = true
rgw usage log tick interval = {{ radosgw_usage_log_tick_interval }}
rgw usage log flush threshold = {{ radosgw_usage_log_flush_threshold }}
rgw usage max shards = {{ radosgw_usage_max_shards }}
rgw usage max user shards = {{ radosgw_usage_max_user_shards }}
{% endif %}
{% if radosgw_static_website | bool %}
rgw enable static website = {{ radosgw_static_website }}
rgw dns s3website name = {{ radosgw_dns_s3website_name }}
{% endif %}
{% endfor %} {% endfor %}
{% endif %} {% endif %}