diff --git a/group_vars/all.yml.sample b/group_vars/all.yml.sample index c3956abbb..1a5fbd80a 100644 --- a/group_vars/all.yml.sample +++ b/group_vars/all.yml.sample @@ -289,9 +289,14 @@ dummy: ## Rados Gateway options # #radosgw_dns_name: your.subdomain.tld # subdomains used by radosgw. See http://ceph.com/docs/master/radosgw/config/#enabling-subdomain-s3-calls +#radosgw_resolve_cname: false # enable for radosgw to resolve DNS CNAME based bucket names #radosgw_civetweb_port: 8080 # on Infernalis we get: "set_ports_option: cannot bind to 80: 13 (Permission denied)" #radosgw_civetweb_bind_ip: "{{ ansible_default_ipv4.address }}" #radosgw_civetweb_num_threads: 50 +# For additional civetweb configuration options available such as SSL, logging, +# keepalive, and timeout settings, please see the civetweb docs at +# https://github.com/civetweb/civetweb/blob/master/docs/UserManual.md +#radosgw_civetweb_options: "port={{ radosgw_civetweb_bind_ip }}:{{ radosgw_civetweb_port }} num_threads={{ radosgw_civetweb_num_threads }}" #radosgw_keystone: false # activate OpenStack Keystone options full detail here: http://ceph.com/docs/master/radosgw/keystone/ #radosgw_keystone_url: # url:admin_port ie: http://192.168.0.1:35357 #radosgw_keystone_api_version: 2 # API versions 2 and 3 are supported @@ -309,6 +314,15 @@ dummy: #radosgw_keystone_revocation_internal: 900 #radosgw_s3_auth_use_keystone: "true" #radosgw_nss_db_path: /var/lib/ceph/radosgw/ceph-radosgw.{{ ansible_hostname }}/nss +# Settings for the RGW usage logging described at http://docs.ceph.com/docs/jewel/man/8/radosgw/#usage-logging +#radosgw_usage_log: false +#radosgw_usage_log_tick_interval: 30 +#radosgw_usage_log_flush_threshold: 1024 +#radosgw_usage_max_shards: 32 +#radosgw_usage_max_user_shards: 1 +# Settings for static website hosting +#radosgw_static_website: false +#radosgw_dns_s3website_name: your.subdomain.tld # subdomain used by radosgw for website bucket hosting. # Rados Gateway options #email_address: foo@bar.com diff --git a/roles/ceph-common/defaults/main.yml b/roles/ceph-common/defaults/main.yml index 036f3bf3d..37d7f5f26 100644 --- a/roles/ceph-common/defaults/main.yml +++ b/roles/ceph-common/defaults/main.yml @@ -281,9 +281,14 @@ mds_max_mds: 3 ## Rados Gateway options # #radosgw_dns_name: your.subdomain.tld # subdomains used by radosgw. See http://ceph.com/docs/master/radosgw/config/#enabling-subdomain-s3-calls +radosgw_resolve_cname: false # enable for radosgw to resolve DNS CNAME based bucket names radosgw_civetweb_port: 8080 # on Infernalis we get: "set_ports_option: cannot bind to 80: 13 (Permission denied)" radosgw_civetweb_bind_ip: "{{ ansible_default_ipv4.address }}" radosgw_civetweb_num_threads: 50 +# For additional civetweb configuration options available such as SSL, logging, +# keepalive, and timeout settings, please see the civetweb docs at +# https://github.com/civetweb/civetweb/blob/master/docs/UserManual.md +radosgw_civetweb_options: "port={{ radosgw_civetweb_bind_ip }}:{{ radosgw_civetweb_port }} num_threads={{ radosgw_civetweb_num_threads }}" radosgw_keystone: false # activate OpenStack Keystone options full detail here: http://ceph.com/docs/master/radosgw/keystone/ #radosgw_keystone_url: # url:admin_port ie: http://192.168.0.1:35357 radosgw_keystone_api_version: 2 # API versions 2 and 3 are supported @@ -301,6 +306,15 @@ radosgw_keystone_token_cache_size: 10000 radosgw_keystone_revocation_internal: 900 radosgw_s3_auth_use_keystone: "true" radosgw_nss_db_path: /var/lib/ceph/radosgw/ceph-radosgw.{{ ansible_hostname }}/nss +# Settings for the RGW usage logging described at http://docs.ceph.com/docs/jewel/man/8/radosgw/#usage-logging +radosgw_usage_log: false +radosgw_usage_log_tick_interval: 30 +radosgw_usage_log_flush_threshold: 1024 +radosgw_usage_max_shards: 32 +radosgw_usage_max_user_shards: 1 +# Settings for static website hosting +radosgw_static_website: false +radosgw_dns_s3website_name: your.subdomain.tld # subdomain used by radosgw for website bucket hosting. # Rados Gateway options email_address: foo@bar.com diff --git a/roles/ceph-common/templates/ceph.conf.j2 b/roles/ceph-common/templates/ceph.conf.j2 index e278a6726..47b2776ac 100644 --- a/roles/ceph-common/templates/ceph.conf.j2 +++ b/roles/ceph-common/templates/ceph.conf.j2 @@ -111,7 +111,8 @@ keyring = /var/lib/ceph/radosgw/{{ cluster }}-rgw.{{ hostvars[host]['ansible_hos rgw socket path = /tmp/radosgw-{{ hostvars[host]['ansible_hostname'] }}.sock log file = /var/log/ceph/{{ cluster }}-rgw-{{ hostvars[host]['ansible_hostname'] }}.log 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 {{ radosgw_civetweb_options }} +rgw resolve cname = {{ radosgw_resolve_cname | bool }} {% if radosgw_keystone %} rgw keystone url = {{ radosgw_keystone_url }} rgw keystone api version = {{ radosgw_keystone_api_version }} @@ -131,6 +132,17 @@ rgw s3 auth use keystone = {{ radosgw_s3_auth_use_keystone }} nss db path = {{ radosgw_nss_db_path }} {% 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 %} {% endif %} {% endfor %} {% endif %}