openstack-ansible-os_swift/templates/object-server.conf.j2
Matthew Oliver c79547cb91 Add statsd configuration for swift
This adds the optional configuration options:
  - statsd_host
  - statsd_port
  - statsd_metric_prefix (defaults to inventory_hostname)
  - statsd_default_sample_rate
  - statsd_sample_rate_factor

Which can be defined under swift globally or on the server level.
The configuration will only be added if statsd_host is defined.

Change-Id: I793b189e0a1f5ca4fc1fe17b1d89f2a83af8c796
2016-01-14 10:20:41 +00:00

53 lines
1.2 KiB
Django/Jinja

# {{ ansible_managed }}
{% set _api_threads = ansible_processor_vcpus|default(2) // 2 %}
{% set api_threads = _api_threads if _api_threads > 0 else 1 %}
[DEFAULT]
bind_ip = {{ swift_storage_address }}
bind_port = {{ swift_object_port }}
workers = {{ swift_object_server_workers | default(api_threads) }}
user = {{ swift_system_user_name }}
swift_dir = /etc/swift
devices = {{ swift_vars.mount_point | default(swift.mount_point) }}
log_facility = LOG_LOCAL4
{% include "statsd.j2" %}
[pipeline:main]
pipeline = healthcheck recon object-server
[app:object-server]
use = egg:swift#object
log_facility = LOG_LOCAL4
mb_per_sync = 64
[filter:healthcheck]
use = egg:swift#healthcheck
[filter:recon]
use = egg:swift#recon
log_facility = LOG_LOCAL4
recon_cache_path = /var/cache/swift
recon_lock_path = /var/lock
{% if swift.replication_network is not defined or swift.replication_network == swift.storage_network %}
[object-replicator]
log_facility = LOG_LOCAL4
concurrency = 6
reclaim_age = {{ reclaim_age | default(604800) }}
{% endif %}
[object-updater]
log_facility = LOG_LOCAL4
concurrency = 3
concurrency = 3
node_timeout = 60
conn_timeout = 5
[object-auditor]
log_facility = LOG_LOCAL4
[filter:xprofile]
use = egg:swift#xprofile