From 9e57ceb7e500297e1e4c29b89ee4a8390e5a26d9 Mon Sep 17 00:00:00 2001 From: Paolino Paperino <paperino@paperopoli.com> Date: Fri, 2 Feb 2018 16:06:14 +0100 Subject: [PATCH] Removed ~ files --- bundles/ceilometer/README.md~ | 98 --- .../templates/mitaka/ceilometer.conf~ | 123 --- bundles/gnocchi/lib/gnocchi_utils.py~ | 439 ----------- .../gnocchi/templates/mitaka/gnocchi.conf~ | 726 ------------------ 4 files changed, 1386 deletions(-) delete mode 100644 bundles/ceilometer/README.md~ delete mode 100644 bundles/ceilometer/templates/mitaka/ceilometer.conf~ delete mode 100644 bundles/gnocchi/lib/gnocchi_utils.py~ delete mode 100644 bundles/gnocchi/templates/mitaka/gnocchi.conf~ diff --git a/bundles/ceilometer/README.md~ b/bundles/ceilometer/README.md~ deleted file mode 100644 index 01e6789a..00000000 --- a/bundles/ceilometer/README.md~ +++ /dev/null @@ -1,98 +0,0 @@ -Overview --------- - -This charm provides the Ceilometer service for OpenStack. It is intended to -be used alongside the other OpenStack components, starting with the Folsom -release. - -Ceilometer is made up of 2 separate services: an API service, and a collector -service. This charm allows them to be deployed in different combination, -depending on user preference and requirements. - -This charm was developed to support deploying Folsom on both Ubuntu Quantal -and Ubuntu Precise. Since Ceilometer is only available for Ubuntu 12.04 via -the Ubuntu Cloud Archive, deploying this charm to a Precise machine will by -default install Ceilometer and its dependencies from the Cloud Archive. - -Usage ------ - -In order to deploy Ceilometer service, the MongoDB service is required: - - juju deploy mongodb - juju deploy ceilometer - juju add-relation ceilometer mongodb - -then Keystone and Rabbit relationships need to be established: - - juju add-relation ceilometer rabbitmq - juju add-relation ceilometer keystone:identity-service - juju add-relation ceilometer keystone:identity-notifications - -In order to capture the calculations, a Ceilometer compute agent needs to be -installed in each nova node, and be related with Ceilometer service: - - juju deploy ceilometer-agent - juju add-relation ceilometer-agent nova-compute - juju add-relation ceilometer:ceilometer-service ceilometer-agent:ceilometer-service - -Ceilometer provides an API service that can be used to retrieve -Openstack metrics. - -HA/Clustering -------------- - -There are two mutually exclusive high availability options: using virtual -IP(s) or DNS. In both cases, a relationship to hacluster is required which -provides the corosync back end HA functionality. - -To use virtual IP(s) the clustered nodes must be on the same subnet such that -the VIP is a valid IP on the subnet for one of the node's interfaces and each -node has an interface in said subnet. The VIP becomes a highly-available API -endpoint. - -At a minimum, the config option 'vip' must be set in order to use virtual IP -HA. If multiple networks are being used, a VIP should be provided for each -network, separated by spaces. Optionally, vip_iface or vip_cidr may be -specified. - -To use DNS high availability there are several prerequisites. However, DNS HA -does not require the clustered nodes to be on the same subnet. -Currently the DNS HA feature is only available for MAAS 2.0 or greater -environments. MAAS 2.0 requires Juju 2.0 or greater. The clustered nodes must -have static or "reserved" IP addresses registered in MAAS. The DNS hostname(s) -must be pre-registered in MAAS before use with DNS HA. - -At a minimum, the config option 'dns-ha' must be set to true and at least one -of 'os-public-hostname', 'os-internal-hostname' or 'os-internal-hostname' must -be set in order to use DNS HA. One or more of the above hostnames may be set. - -The charm will throw an exception in the following circumstances: -If neither 'vip' nor 'dns-ha' is set and the charm is related to hacluster -If both 'vip' and 'dns-ha' are set as they are mutually exclusive -If 'dns-ha' is set and none of the os-{admin,internal,public}-hostname(s) are -set - -Network Space support ---------------------- - -This charm supports the use of Juju Network Spaces, allowing the charm to be bound to network space configurations managed directly by Juju. This is only supported with Juju 2.0 and above. - -API endpoints can be bound to distinct network spaces supporting the network separation of public, internal and admin endpoints. - -To use this feature, use the --bind option when deploying the charm: - - juju deploy ceilometer --bind "public=public-space internal=internal-space admin=admin-space" - -alternatively these can also be provided as part of a juju native bundle configuration: - - ceilometer: - charm: cs:xenial/ceilometer - bindings: - public: public-space - admin: admin-space - internal: internal-space - -NOTE: Spaces must be configured in the underlying provider prior to attempting to use them. - -NOTE: Existing deployments using os-*-network configuration options will continue to function; these options are preferred over any network space binding provided if set. diff --git a/bundles/ceilometer/templates/mitaka/ceilometer.conf~ b/bundles/ceilometer/templates/mitaka/ceilometer.conf~ deleted file mode 100644 index 9faaf004..00000000 --- a/bundles/ceilometer/templates/mitaka/ceilometer.conf~ +++ /dev/null @@ -1,123 +0,0 @@ -# mitaka -############################################################################### -# [ WARNING ] -# ceilometer configuration file maintained by Juju -# local changes may be overwritten. -############################################################################### -[DEFAULT] -debug = {{ debug }} -verbose = {{ verbose }} -use_syslog = {{ use_syslog }} -# Configuration file for pipeline definition. (string value) -pipeline_cfg_file = /etc/ceilometer/pipeline.yaml - -# Configuration file for event pipeline definition. (string value) -event_pipeline_cfg_file = /etc/ceilometer/event_pipeline_alarm.yaml - -[api] -# DEPRECATED (Attardi) -port = {{ port }} -workers = {{ api_workers }} - -[dispatcher_gnocchi] - -# Filter out samples generated by Gnocchi service activity (boolean value) -filter_service_activity = False # Enable if using swift backend - -# Gnocchi project used to filter out samples generated by Gnocchi service -# activity (string value) -#filter_project = gnocchi # if using swift backend - -{% if service_host -%} -[service_credentials] -auth_url = {{ service_protocol }}://{{ service_host }}:{{ service_port }} -project_name = service -username = ceilometer -password = {{ admin_password }} -{% if api_version == "3" -%} -project_domain_name = {{ admin_domain_name }} -user_domain_name = {{ admin_domain_name }} -{% else -%} -project_domain_name = default -user_domain_name = default -{% endif -%} -auth_type = password -{% endif -%} - -# Disable keystone authentication for Gnocchi to increase performance: -# auth_section=service_credentials_gnocchi - -# auth_type=gnocchi-noauth -# roles = admin -# user_id = <ceilometer_user_id> -# project_id = <ceilometer_project_id> -# endpoint = <gnocchi_endpoint> - -[database] -{% if db_replset: -%} -connection = mongodb://{{ db_mongo_servers }}/{{ db_name }}?readPreference=primaryPreferred&replicaSet={{ db_replset }} -mongodb_replica_set = {{ db_replset }} -{% else -%} -connection = mongodb://{{ db_host }}:{{ db_port }}/{{ db_name }} -{% endif %} -metering_time_to_live = {{ metering_time_to_live }} -event_time_to_live = {{ event_time_to_live }} - -[publisher] -telemetry_secret = {{ metering_secret }} - -{% include "section-keystone-authtoken-mitaka" %} - -{% include "section-rabbitmq-oslo" %} - -[notification] - -# Number of queues to parallelize workload across. This value should be larger -# than the number of active notification agents for optimal results. WARNING: -# Once set, lowering this value may result in lost data. (integer value) -# Minimum value: 1 -#pipeline_processing_queues = 10 - -# Acknowledge message when event persistence fails. (boolean value) -#ack_on_event_error = true - -# Enable workload partitioning, allowing multiple notification agents to be run -# simultaneously. (boolean value) -#workload_partitioning = false - -# Messaging URLs to listen for notifications. Example: -# rabbit://user:pass@host1:port1[,user:pass@hostN:portN]/virtual_host -# (DEFAULT/transport_url is used if empty). This is useful when you have -# dedicate messaging nodes for each service, for example, all nova -# notifications go to rabbit-nova:5672, while all cinder notifications go to -# rabbit-cinder:5672. (multi valued) -#messaging_urls = - -# Number of notification messages to wait before publishing them. Batching is -# advised when transformations are applied in pipeline. (integer value) -# Minimum value: 1 -#batch_size = 100 - -# Number of seconds to wait before publishing samples when batch_size is not -# reached (None means indefinitely) (integer value) -#batch_timeout = 5 - -# Number of workers for notification service, default value is 1. (integer -# value) -# Minimum value: 1 -#workers = 1 - -# Exchanges name to listen for notifications. (multi valued) -#notification_control_exchanges = nova -#notification_control_exchanges = glance -#notification_control_exchanges = neutron -#notification_control_exchanges = cinder -#notification_control_exchanges = heat -#notification_control_exchanges = keystone -#notification_control_exchanges = sahara -#notification_control_exchanges = trove -#notification_control_exchanges = zaqar -#notification_control_exchanges = swift -#notification_control_exchanges = ceilometer -#notification_control_exchanges = magnum -#notification_control_exchanges = dns diff --git a/bundles/gnocchi/lib/gnocchi_utils.py~ b/bundles/gnocchi/lib/gnocchi_utils.py~ deleted file mode 100644 index ae68e1dc..00000000 --- a/bundles/gnocchi/lib/gnocchi_utils.py~ +++ /dev/null @@ -1,439 +0,0 @@ -# Copyright 2016 Canonical Ltd -# -# 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. - -import os -import uuid -import subprocess - -from collections import OrderedDict - -from charmhelpers.contrib.openstack import ( - templating, - context, -) -from ceilometer_contexts import ( - ApacheSSLContext, - LoggingConfigContext, - MongoDBContext, - CeilometerContext, - HAProxyContext, - CEILOMETER_PORT, -) -from charmhelpers.contrib.openstack.utils import ( - get_os_codename_package, - get_os_codename_install_source, - configure_installation_source, - os_release, - pause_unit, - resume_unit, - make_assess_status_func, - os_application_version_set, - token_cache_pkgs, - enable_memcache, - CompareOpenStackReleases, -) -from charmhelpers.core.hookenv import config, log -from charmhelpers.fetch import apt_update, apt_install, apt_upgrade -from charmhelpers.core.host import init_is_systemd -from copy import deepcopy - -HAPROXY_CONF = '/etc/haproxy/haproxy.cfg' -CEILOMETER_CONF_DIR = "/etc/ceilometer" -CEILOMETER_CONF = "%s/ceilometer.conf" % CEILOMETER_CONF_DIR -CEILOMETER_API_SYSTEMD_CONF = ( - '/etc/systemd/system/ceilometer-api.service.d/override.conf' -) -HTTPS_APACHE_CONF = "/etc/apache2/sites-available/openstack_https_frontend" -HTTPS_APACHE_24_CONF = "/etc/apache2/sites-available/" \ - "openstack_https_frontend.conf" -CLUSTER_RES = 'grp_ceilometer_vips' -MEMCACHED_CONF = '/etc/memcached.conf' - -CEILOMETER_BASE_SERVICES = [ - 'ceilometer-agent-central', - 'ceilometer-collector', - 'ceilometer-api', -] - -ICEHOUSE_SERVICES = [ - 'ceilometer-alarm-notifier', - 'ceilometer-alarm-evaluator', - 'ceilometer-agent-notification' -] - -MITAKA_SERVICES = [ - 'ceilometer-agent-notification' -] - -CEILOMETER_DB = "ceilometer" -CEILOMETER_SERVICE = "ceilometer" - -CEILOMETER_BASE_PACKAGES = [ - 'haproxy', - 'apache2', - 'ceilometer-agent-central', - 'ceilometer-collector', - 'ceilometer-api', - 'python-pymongo', -] - -ICEHOUSE_PACKAGES = [ - 'ceilometer-alarm-notifier', - 'ceilometer-alarm-evaluator', - 'ceilometer-agent-notification' -] - -MITAKA_PACKAGES = [ - 'ceilometer-agent-notification' -] - -REQUIRED_INTERFACES = { - 'database': ['mongodb'], - 'messaging': ['amqp'], - 'identity': ['identity-service'], -} - -CEILOMETER_ROLE = "ResellerAdmin" -SVC = 'ceilometer' -WSGI_CEILOMETER_API_CONF = '/etc/apache2/sites-enabled/wsgi-openstack-api.conf' -PACKAGE_CEILOMETER_API_CONF = '/etc/apache2/sites-enabled/ceilometer-api.conf' - -CONFIG_FILES = OrderedDict([ - (CEILOMETER_CONF, { - 'hook_contexts': [context.IdentityServiceContext(service=SVC, - service_user=SVC), - context.AMQPContext(ssl_dir=CEILOMETER_CONF_DIR), - LoggingConfigContext(), - MongoDBContext(), - CeilometerContext(), - context.SyslogContext(), - HAProxyContext(), - context.MemcacheContext()], - 'services': CEILOMETER_BASE_SERVICES - }), - (CEILOMETER_API_SYSTEMD_CONF, { - 'hook_contexts': [HAProxyContext()], - 'services': ['ceilometer-api'], - }), - (HAPROXY_CONF, { - 'hook_contexts': [context.HAProxyContext(singlenode_mode=True), - HAProxyContext()], - 'services': ['haproxy'], - }), - (HTTPS_APACHE_CONF, { - 'hook_contexts': [ApacheSSLContext()], - # Include ceilometer-api to fix Bug #1632287 This is a temporary - # tactival fix as the charm will be rewritten to use mod_wsgi next - # cycle - 'services': ['ceilometer-api', 'apache2'], - }), - (HTTPS_APACHE_24_CONF, { - 'hook_contexts': [ApacheSSLContext()], - 'services': ['ceilometer-api', 'apache2'], - }), -]) - -TEMPLATES = 'templates' - -SHARED_SECRET = "/etc/ceilometer/secret.txt" - -VERSION_PACKAGE = 'ceilometer-common' - - -def register_configs(): - """ - Register config files with their respective contexts. - Regstration of some configs may not be required depending on - existing of certain relations. - """ - # if called without anything installed (eg during install hook) - # just default to earliest supported release. configs dont get touched - # till post-install, anyway. - release = (get_os_codename_package('ceilometer-common', fatal=False) or - 'grizzly') - configs = templating.OSConfigRenderer(templates_dir=TEMPLATES, - openstack_release=release) - - for conf in (CEILOMETER_CONF, HAPROXY_CONF): - configs.register(conf, CONFIG_FILES[conf]['hook_contexts']) - - if init_is_systemd(): - configs.register( - CEILOMETER_API_SYSTEMD_CONF, - CONFIG_FILES[CEILOMETER_API_SYSTEMD_CONF]['hook_contexts'] - ) - - if os.path.exists('/etc/apache2/conf-available'): - configs.register(HTTPS_APACHE_24_CONF, - CONFIG_FILES[HTTPS_APACHE_24_CONF]['hook_contexts']) - else: - configs.register(HTTPS_APACHE_CONF, - CONFIG_FILES[HTTPS_APACHE_CONF]['hook_contexts']) - if enable_memcache(release=release): - configs.register(MEMCACHED_CONF, [context.MemcacheContext()]) - - if run_in_apache(): - wsgi_script = "/usr/share/ceilometer/app.wsgi" - configs.register(WSGI_CEILOMETER_API_CONF, - [context.WSGIWorkerConfigContext(name="ceilometer", - script=wsgi_script), - CeilometerContext(), - HAProxyContext()]) - return configs - - -def restart_map(): - """ - Determine the correct resource map to be passed to - charmhelpers.core.restart_on_change() based on the services configured. - - :returns: dict: A dictionary mapping config file to lists of services - that should be restarted when file changes. - """ - _map = {} - for f, ctxt in CONFIG_FILES.iteritems(): - svcs = [] - for svc in ctxt['services']: - svcs.append(svc) - if f == CEILOMETER_CONF: - for svc in ceilometer_release_services(): - svcs.append(svc) - if svcs: - _map[f] = svcs - - if enable_memcache(source=config('openstack-origin')): - _map[MEMCACHED_CONF] = ['memcached'] - - if run_in_apache(): - for cfile in _map: - svcs = _map[cfile] - if 'ceilometer-api' in svcs: - svcs.remove('ceilometer-api') - if 'apache2' not in svcs: - svcs.append('apache2') - _map['WSGI_CEILOMETER_API_CONF'] = ['apache2'] - - return _map - - -def services(): - """ Returns a list of services associate with this charm """ - _services = [] - for v in restart_map().values(): - _services = _services + v - _services = set(_services) - # Bug#1664898 Remove check for ceilometer-agent-central - # service. - cmp_codename = CompareOpenStackReleases( - get_os_codename_install_source(config('openstack-origin'))) - if cmp_codename >= 'liberty' and 'ceilometer-agent-central' in _services: - _services.remove('ceilometer-agent-central') - return list(_services) - - -def determine_ports(): - """Assemble a list of API ports for services the charm is managing - - @returns [ports] - list of ports that the charm manages. - """ - # TODO(ajkavanagh) - determine what other ports the service listens on - # apart from the main CEILOMETER port - ports = [CEILOMETER_PORT] - return ports - - -def get_ceilometer_context(): - """ Retrieve a map of all current relation data for agent configuration """ - ctxt = {} - for hcontext in CONFIG_FILES[CEILOMETER_CONF]['hook_contexts']: - ctxt.update(hcontext()) - return ctxt - - -def do_openstack_upgrade(configs): - """ - Perform an upgrade. Takes care of upgrading packages, rewriting - configs, database migrations and potentially any other post-upgrade - actions. - - :param configs: The charms main OSConfigRenderer object. - """ - new_src = config('openstack-origin') - new_os_rel = get_os_codename_install_source(new_src) - - log('Performing OpenStack upgrade to %s.' % (new_os_rel)) - - configure_installation_source(new_src) - dpkg_opts = [ - '--option', 'Dpkg::Options::=--force-confnew', - '--option', 'Dpkg::Options::=--force-confdef', - ] - apt_update(fatal=True) - apt_upgrade(options=dpkg_opts, fatal=True, dist=True) - apt_install(packages=get_packages(), - options=dpkg_opts, - fatal=True) - - # set CONFIGS to load templates from new release - configs.set_release(openstack_release=new_os_rel) - - if run_in_apache(): - disable_package_apache_site() - - -def ceilometer_release_services(): - cmp_codename = CompareOpenStackReleases( - get_os_codename_install_source(config('openstack-origin'))) - if cmp_codename >= 'mitaka': - return MITAKA_SERVICES - elif cmp_codename >= 'icehouse': - return ICEHOUSE_SERVICES - else: - return [] - - -def ceilometer_release_packages(): - cmp_codename = CompareOpenStackReleases( - get_os_codename_install_source(config('openstack-origin'))) - if cmp_codename >= 'mitaka': - return MITAKA_PACKAGES - elif cmp_codename >= 'icehouse': - return ICEHOUSE_PACKAGES - else: - return [] - - -def get_packages(): - packages = (deepcopy(CEILOMETER_BASE_PACKAGES) + - ceilometer_release_packages()) - packages.extend(token_cache_pkgs(source=config('openstack-origin'))) - return packages - - -def get_shared_secret(): - """ - Returns the current shared secret for the ceilometer node. If the shared - secret does not exist, this method will generate one. - """ - secret = None - if not os.path.exists(SHARED_SECRET): - secret = str(uuid.uuid4()) - set_shared_secret(secret) - else: - with open(SHARED_SECRET, 'r') as secret_file: - secret = secret_file.read().strip() - return secret - - -def set_shared_secret(secret): - """ - Sets the shared secret which is used to sign ceilometer messages. - - :param secret: the secret to set - """ - with open(SHARED_SECRET, 'w') as secret_file: - secret_file.write(secret) - - -def assess_status(configs): - """Assess status of current unit - - Decides what the state of the unit should be based on the current - configuration. - - SIDE EFFECT: calls set_os_workload_status(...) which sets the workload - status of the unit. - Also calls status_set(...) directly if paused state isn't complete. - - @param configs: a templating.OSConfigRenderer() object - @returns None - this function is executed for its side-effect - """ - assess_status_func(configs)() - os_application_version_set(VERSION_PACKAGE) - - -def assess_status_func(configs): - """Helper function to create the function that will assess_status() for - the unit. - Uses charmhelpers.contrib.openstack.utils.make_assess_status_func() to - create the appropriate status function and then returns it. - Used directly by assess_status() and also for pausing and resuming - the unit. - - @param configs: a templating.OSConfigRenderer() object - @return f() -> None : a function that assesses the unit's workload status - """ - return make_assess_status_func( - configs, REQUIRED_INTERFACES, - services=services(), ports=determine_ports()) - - -def pause_unit_helper(configs): - """Helper function to pause a unit, and then call assess_status(...) in - effect, so that the status is correctly updated. - Uses charmhelpers.contrib.openstack.utils.pause_unit() to do the work. - - @param configs: a templating.OSConfigRenderer() object - @returns None - this function is executed for its side-effect - """ - _pause_resume_helper(pause_unit, configs) - - -def resume_unit_helper(configs): - """Helper function to resume a unit, and then call assess_status(...) in - effect, so that the status is correctly updated. - Uses charmhelpers.contrib.openstack.utils.resume_unit() to do the work. - - @param configs: a templating.OSConfigRenderer() object - @returns None - this function is executed for its side-effect - """ - _pause_resume_helper(resume_unit, configs) - - -def _pause_resume_helper(f, configs): - """Helper function that uses the make_assess_status_func(...) from - charmhelpers.contrib.openstack.utils to create an assess_status(...) - function that can be used with the pause/resume of the unit - - @param f: the function to be used with the assess_status(...) function - @returns None - this function is executed for its side-effect - """ - # TODO(ajkavanagh) - ports= has been left off because of the race hazard - # that exists due to service_start() - f(assess_status_func(configs), - services=services(), - ports=determine_ports()) - - -# NOTE(jamespage): Drop once charm switches to apache+mod_wsgi. -def reload_systemd(): - """Reload systemd configuration on systemd based installs - """ - if init_is_systemd(): - subprocess.check_call(['systemctl', 'daemon-reload']) - - -def run_in_apache(): - """Return true if ceilometer API is run under apache2 with mod_wsgi in - this release. - """ - return CompareOpenStackReleases(os_release('ceilometer-common')) >= 'ocata' - - -def disable_package_apache_site(): - """Ensure that the package-provided apache configuration is disabled to - prevent it from conflicting with the charm-provided version. - """ - if os.path.exists(PACKAGE_CEILOMETER_API_CONF): - subprocess.check_call(['a2dissite', 'ceilometer-api']) diff --git a/bundles/gnocchi/templates/mitaka/gnocchi.conf~ b/bundles/gnocchi/templates/mitaka/gnocchi.conf~ deleted file mode 100644 index abe2888d..00000000 --- a/bundles/gnocchi/templates/mitaka/gnocchi.conf~ +++ /dev/null @@ -1,726 +0,0 @@ -# mitaka -############################################################################### -# [ WARNING ] -# ceilometer configuration file maintained by Juju -# local changes may be overwritten. -############################################################################### -[DEFAULT] - -# -# From cotyledon -# - -# Enables or disables logging values of all registered options when starting a -# service (at DEBUG level). (boolean value) -# Note: This option can be changed without restarting. -#log_options = true - -# Specify a timeout after which a gracefully shutdown server will exit. Zero -# value means endless wait. (integer value) -# Note: This option can be changed without restarting. -#graceful_shutdown_timeout = 60 - -# -# From oslo.log -# - -# If set to true, the logging level will be set to DEBUG instead of the default -# INFO level. (boolean value) -# Note: This option can be changed without restarting. -#debug = false - -# The name of a logging configuration file. This file is appended to any -# existing logging configuration files. For details about logging configuration -# files, see the Python logging module documentation. Note that when logging -# configuration files are used then all logging configuration is set in the -# configuration file and other logging configuration options are ignored (for -# example, logging_context_format_string). (string value) -# Note: This option can be changed without restarting. -#log_config_append = <None> - -# Defines the format string for %%(asctime)s in log records. Default: -# %(default)s . This option is ignored if log_config_append is set. (string -# value) -#log_date_format = %Y-%m-%d %H:%M:%S - -# (Optional) Name of log file to send logging output to. If no default is set, -# logging will go to stderr as defined by use_stderr. This option is ignored if -# log_config_append is set. (string value) -#log_file = <None> - -# (Optional) The base directory used for relative log_file paths. This option -# is ignored if log_config_append is set. (string value) -#log_dir = <None> - -# Uses logging handler designed to watch file system. When log file is moved or -# removed this handler will open a new log file with specified path -# instantaneously. It makes sense only if log_file option is specified and -# Linux platform is used. This option is ignored if log_config_append is set. -# (boolean value) -#watch_log_file = false - -# Use syslog for logging. Existing syslog format is DEPRECATED and will be -# changed later to honor RFC5424. This option is ignored if log_config_append -# is set. (boolean value) -#use_syslog = false - -# Enable journald for logging. If running in a systemd environment you may wish -# to enable journal support. Doing so will use the journal native protocol -# which includes structured metadata in addition to log messages.This option is -# ignored if log_config_append is set. (boolean value) -#use_journal = false - -# Syslog facility to receive log lines. This option is ignored if -# log_config_append is set. (string value) -#syslog_log_facility = LOG_USER - -# Log output to standard error. This option is ignored if log_config_append is -# set. (boolean value) -#use_stderr = false - -# Format string to use for log messages with context. (string value) -#logging_context_format_string = %(asctime)s.%(msecs)03d %(process)d %(levelname)s %(name)s [%(request_id)s %(user_identity)s] %(instance)s%(message)s - -# Format string to use for log messages when context is undefined. (string -# value) -#logging_default_format_string = %(asctime)s.%(msecs)03d %(process)d %(levelname)s %(name)s [-] %(instance)s%(message)s - -# Additional data to append to log message when logging level for the message -# is DEBUG. (string value) -#logging_debug_format_suffix = %(funcName)s %(pathname)s:%(lineno)d - -# Prefix each line of exception output with this format. (string value) -#logging_exception_prefix = %(asctime)s.%(msecs)03d %(process)d ERROR %(name)s %(instance)s - -# Defines the format string for %(user_identity)s that is used in -# logging_context_format_string. (string value) -#logging_user_identity_format = %(user)s %(tenant)s %(domain)s %(user_domain)s %(project_domain)s - -# List of package logging levels in logger=LEVEL pairs. This option is ignored -# if log_config_append is set. (list value) -#default_log_levels = amqp=WARN,amqplib=WARN,boto=WARN,qpid=WARN,sqlalchemy=WARN,suds=INFO,oslo.messaging=INFO,oslo_messaging=INFO,iso8601=WARN,requests.packages.urllib3.connectionpool=WARN,urllib3.connectionpool=WARN,websocket=WARN,requests.packages.urllib3.util.retry=WARN,urllib3.util.retry=WARN,keystonemiddleware=WARN,routes.middleware=WARN,stevedore=WARN,taskflow=WARN,keystoneauth=WARN,oslo.cache=INFO,dogpile.core.dogpile=INFO - -# Enables or disables publication of error events. (boolean value) -#publish_errors = false - -# The format for an instance that is passed with the log message. (string -# value) -#instance_format = "[instance: %(uuid)s] " - -# The format for an instance UUID that is passed with the log message. (string -# value) -#instance_uuid_format = "[instance: %(uuid)s] " - -# Interval, number of seconds, of log rate limiting. (integer value) -#rate_limit_interval = 0 - -# Maximum number of logged messages per rate_limit_interval. (integer value) -#rate_limit_burst = 0 - -# Log level name used by rate limiting: CRITICAL, ERROR, INFO, WARNING, DEBUG -# or empty string. Logs with level greater or equal to rate_limit_except_level -# are not filtered. An empty string means that all levels are filtered. (string -# value) -#rate_limit_except_level = CRITICAL - -# Enables or disables fatal status of deprecations. (boolean value) -#fatal_deprecations = false - - -[api] - -# -# From gnocchi -# - -# Path to API Paste configuration. (string value) -#paste_config = /usr/local/lib/python3.5/dist-packages/gnocchi/rest/api-paste.ini - -# Authentication mode to use. (string value) -# Allowed values: basic, noauth, keystone -auth_mode = {{ auth_mode }} - -# The maximum number of items returned in a single response from a collection -# resource (integer value) -#max_limit = 1000 - - -[archive_policy] - -# -# From gnocchi -# - -# Default aggregation methods to use in created archive policies (list value) -#default_aggregation_methods = mean,min,max,sum,std,count - - -[cors] - -# -# From oslo.middleware.cors -# - -# Indicate whether this resource may be shared with the domain received in the -# requests "origin" header. Format: "<protocol>://<host>[:<port>]", no trailing -# slash. Example: https://horizon.example.com (list value) -#allowed_origin = <None> - -# Indicate that the actual request can include user credentials (boolean value) -#allow_credentials = true - -# Indicate which headers are safe to expose to the API. Defaults to HTTP Simple -# Headers. (list value) -#expose_headers = - -# Maximum cache age of CORS preflight requests. (integer value) -#max_age = 3600 - -# Indicate which methods can be used during the actual request. (list value) -#allow_methods = OPTIONS,GET,HEAD,POST,PUT,DELETE,TRACE,PATCH - -# Indicate which header field names may be used during the actual request. -# (list value) -#allow_headers = X-Auth-Token,X-Subject-Token,X-User-Id,X-Domain-Id,X-Project-Id,X-Roles - - -[cors.subdomain] - -# -# From oslo.middleware.cors -# - -# Indicate whether this resource may be shared with the domain received in the -# requests "origin" header. Format: "<protocol>://<host>[:<port>]", no trailing -# slash. Example: https://horizon.example.com (list value) -#allowed_origin = <None> - -# Indicate that the actual request can include user credentials (boolean value) -#allow_credentials = true - -# Indicate which headers are safe to expose to the API. Defaults to HTTP Simple -# Headers. (list value) -#expose_headers = - -# Maximum cache age of CORS preflight requests. (integer value) -#max_age = 3600 - -# Indicate which methods can be used during the actual request. (list value) -#allow_methods = OPTIONS,GET,HEAD,POST,PUT,DELETE,TRACE,PATCH - -# Indicate which header field names may be used during the actual request. -# (list value) -#allow_headers = X-Auth-Token,X-Subject-Token,X-User-Id,X-Domain-Id,X-Project-Id,X-Roles - - -[database] - -# -# From oslo.db -# - -# If True, SQLite uses synchronous mode. (boolean value) -#sqlite_synchronous = true - -# The back end to use for the database. (string value) -#backend = sqlalchemy - -# The SQLAlchemy connection string to use to connect to the database. (string -# value) -#connection = <None> - -# The SQLAlchemy connection string to use to connect to the slave database. -# (string value) -#slave_connection = <None> - -# The SQL mode to be used for MySQL sessions. This option, including the -# default, overrides any server-set SQL mode. To use whatever SQL mode is set -# by the server configuration, set this to no value. Example: mysql_sql_mode= -# (string value) -#mysql_sql_mode = TRADITIONAL - -# Timeout before idle SQL connections are reaped. (integer value) -#idle_timeout = 3600 - -# Minimum number of SQL connections to keep open in a pool. (integer value) -#min_pool_size = 1 - -# Maximum number of SQL connections to keep open in a pool. Setting a value of -# 0 indicates no limit. (integer value) -#max_pool_size = 5 - -# Maximum number of database connection retries during startup. Set to -1 to -# specify an infinite retry count. (integer value) -#max_retries = 10 - -# Interval between retries of opening a SQL connection. (integer value) -#retry_interval = 10 - -# If set, use this value for max_overflow with SQLAlchemy. (integer value) -#max_overflow = 50 - -# Verbosity of SQL debugging information: 0=None, 100=Everything. (integer -# value) -# Minimum value: 0 -# Maximum value: 100 -#connection_debug = 0 - -# Add Python stack traces to SQL as comment strings. (boolean value) -#connection_trace = false - -# If set, use this value for pool_timeout with SQLAlchemy. (integer value) -#pool_timeout = <None> - -# Enable the experimental use of database reconnect on connection lost. -# (boolean value) -#use_db_reconnect = false - -# Seconds between retries of a database transaction. (integer value) -#db_retry_interval = 1 - -# If True, increases the interval between retries of a database operation up to -# db_max_retry_interval. (boolean value) -#db_inc_retry_interval = true - -# If db_inc_retry_interval is set, the maximum seconds between retries of a -# database operation. (integer value) -#db_max_retry_interval = 10 - -# Maximum retries in case of connection error or deadlock error before error is -# raised. Set to -1 to specify an infinite retry count. (integer value) -#db_max_retries = 20 - - -[healthcheck] - -# -# From oslo.middleware.healthcheck -# - -# Show more detailed information as part of the response (boolean value) -#detailed = false - -# Additional backends that can perform health checks and report that -# information back as part of a request. (list value) -#backends = - -# Check the presence of a file to determine if an application is running on a -# port. Used by DisableByFileHealthcheck plugin. (string value) -#disable_by_file_path = <None> - -# Check the presence of a file based on a port to determine if an application -# is running on a port. Expects a "port:path" list of strings. Used by -# DisableByFilesPortsHealthcheck plugin. (list value) -#disable_by_file_paths = - - -[incoming] - -# -# From gnocchi -# - -# Storage driver to use (string value) -driver = {{ storage.driver }} - -# Ceph pool name to use. (string value) -#ceph_pool = {{ storage.ceph_pool }} - -# Ceph username (ie: admin without "client." prefix). (string value) -#ceph_username = {{ storage.ceph_username }} - -# Ceph key (string value) -#ceph_secret = {{ storage.ceph_secret }} - -# Ceph keyring path. (string value) -#ceph_keyring = {{ storage.ceph_keyring }} - -# Ceph configuration file. (string value) -#ceph_conffile = {{ storage.ceph_conffile }} - -# Path used to store gnocchi data files. (string value) -#file_basepath = {{ storage.file_basepath }} - -# Swift authentication version to user. (string value) -#swift_auth_version = {{ storage.swift_auth_version }} - -# Swift pre-auth URL. (string value) -#swift_preauthurl = {{ storage.swift_preauthurl }} - -# Swift auth URL. (string value) -#swift_authurl = {{ storage.swift_authurl }} - -# Swift token to user to authenticate. (string value) -#swift_preauthtoken = {{ storage.swift_preauthtoken }} - -# Swift user. (string value) -#swift_user = {{ storage.swift_user }} - -# Swift user domain name. (string value) -#swift_user_domain_name = {{ storage.swift_user_domain_name }} - -# Swift key/password. (string value) -#swift_key = {{ storage.swift_key }} - -# Swift tenant name, only used in v2/v3 auth. (string value) -#swift_project_name = {{ storage.swift_project_name }} - -# Swift project domain name. (string value) -#swift_project_domain_name = {{ storage.swift_project_domain_name }} - -# Prefix to namespace metric containers. (string value) -#swift_container_prefix = {{ storage.swift_container_prefix }} - -# Endpoint type to connect to Swift (string value) -#swift_endpoint_type = {{ storage.swift_endpoint_type }} - -# Connection timeout in seconds. (integer value) -# Minimum value: 0 -#swift_timeout = {{ storage.swift_timeout }} - -# S3 endpoint URL (string value) -#s3_endpoint_url = {{ storage.s3_endpoint_url }} - -# S3 region name (string value) -#s3_region_name = {{ storage.s3_region_name }} - -# S3 access key id (string value) -#s3_access_key_id = {{ storage.s3_access_key_id }} - -# S3 secret access key (string value) -#s3_secret_access_key = {{ storage.s3_secret_access_key }} - -# Prefix to namespace metric bucket. (string value) -#s3_bucket_prefix = {{ storage.s3_bucket_prefix }} - - -[indexer] - -# -# From gnocchi -# - -# Indexer driver to use (string value) -# added database_port PostgresqlDBContext(), Attardi -url = {{ database_type }}://{{ database_user}}:{{ database_password }}@{{ database_host }}:{{ database_port }}/{{ database }} - - -[keystone_authtoken] - -# -# From keystonemiddleware.auth_token -# - -# Complete "public" Identity API endpoint. This endpoint should not be an -# "admin" endpoint, as it should be accessible by all end users. -# Unauthenticated clients are redirected to this endpoint to authenticate. -# Although this endpoint should ideally be unversioned, client support in the -# wild varies. If you're using a versioned v2 endpoint here, then this should -# *not* be the same endpoint the service user utilizes for validating tokens, -# because normal end users may not be able to reach that endpoint. (string -# value) -auth_uri = {{ service_protocol }}://{{ service_host }}:{{ service_port }} -auth_url = {{ auth_protocol }}://{{ auth_host }}:{{ auth_port }} -# Newton requires this: -identity_uri = {{ service_protocol }}://{{ service_host }}:{{ service_port }} - -# API version of the admin Identity API endpoint. (string value) -#auth_version = <None> - -# Do not handle authorization requests within the middleware, but delegate the -# authorization decision to downstream WSGI components. (boolean value) -#delay_auth_decision = false - -# Request timeout value for communicating with Identity API server. (integer -# value) -#http_connect_timeout = <None> - -# How many times are we trying to reconnect when communicating with Identity -# API Server. (integer value) -#http_request_max_retries = 3 - -# Request environment key where the Swift cache object is stored. When -# auth_token middleware is deployed with a Swift cache, use this option to have -# the middleware share a caching backend with swift. Otherwise, use the -# ``memcached_servers`` option instead. (string value) -#cache = <None> - -# Required if identity server requires client certificate (string value) -#certfile = <None> - -# Required if identity server requires client certificate (string value) -#keyfile = <None> - -# A PEM encoded Certificate Authority to use when verifying HTTPs connections. -# Defaults to system CAs. (string value) -#cafile = <None> - -# Verify HTTPS connections. (boolean value) -#insecure = false - -# The region in which the identity server can be found. (string value) -region_name = {{ region_name }} - -# Optionally specify a list of memcached server(s) to use for caching. If left -# undefined, tokens will instead be cached in-process. (list value) -#memcached_servers = <None> - -# In order to prevent excessive effort spent validating tokens, the middleware -# caches previously-seen tokens for a configurable duration (in seconds). Set -# to -1 to disable caching completely. (integer value) -#token_cache_time = 300 - -# (Optional) If defined, indicate whether token data should be authenticated or -# authenticated and encrypted. If MAC, token data is authenticated (with HMAC) -# in the cache. If ENCRYPT, token data is encrypted and authenticated in the -# cache. If the value is not one of these options or empty, auth_token will -# raise an exception on initialization. (string value) -# Allowed values: None, MAC, ENCRYPT -#memcache_security_strategy = None - -# (Optional, mandatory if memcache_security_strategy is defined) This string is -# used for key derivation. (string value) -#memcache_secret_key = <None> - -# (Optional) Number of seconds memcached server is considered dead before it is -# tried again. (integer value) -#memcache_pool_dead_retry = 300 - -# (Optional) Maximum total number of open connections to every memcached -# server. (integer value) -#memcache_pool_maxsize = 10 - -# (Optional) Socket timeout in seconds for communicating with a memcached -# server. (integer value) -#memcache_pool_socket_timeout = 3 - -# (Optional) Number of seconds a connection to memcached is held unused in the -# pool before it is closed. (integer value) -#memcache_pool_unused_timeout = 60 - -# (Optional) Number of seconds that an operation will wait to get a memcached -# client connection from the pool. (integer value) -#memcache_pool_conn_get_timeout = 10 - -# (Optional) Use the advanced (eventlet safe) memcached client pool. The -# advanced pool will only work under python 2.x. (boolean value) -#memcache_use_advanced_pool = false - -# (Optional) Indicate whether to set the X-Service-Catalog header. If False, -# middleware will not ask for service catalog on token validation and will not -# set the X-Service-Catalog header. (boolean value) -#include_service_catalog = true - -# Used to control the use and type of token binding. Can be set to: "disabled" -# to not check token binding. "permissive" (default) to validate binding -# information if the bind type is of a form known to the server and ignore it -# if not. "strict" like "permissive" but if the bind type is unknown the token -# will be rejected. "required" any form of token binding is needed to be -# allowed. Finally the name of a binding method that must be present in tokens. -# (string value) -#enforce_token_bind = permissive - -# A choice of roles that must be present in a service token. Service tokens are -# allowed to request that an expired token can be used and so this check should -# tightly control that only actual services should be sending this token. Roles -# here are applied as an ANY check so any role in this list must be present. -# For backwards compatibility reasons this currently only affects the -# allow_expired check. (list value) -#service_token_roles = service - -# For backwards compatibility reasons we must let valid service tokens pass -# that don't pass the service_token_roles check as valid. Setting this true -# will become the default in a future release and should be enabled if -# possible. (boolean value) -#service_token_roles_required = false - -# Authentication type to load (string value) -auth_type = password - -# Config Section from which to load plugin specific options (string value) -#auth_section = <None> - -username = {{ admin_user }} -project_name = {{ admin_project_name }} -{% if api_version == "3" -%} -project_domain_name = {{ admin_domain_name }} -user_domain_name = {{ admin_domain_name }} -{% else -%} -project_domain_name = default -user_domain_name = default -{% endif -%} -password = {{ admin_password }} -signing_dir = {{ signing_dir }} -{% if use_memcache == true %} -memcached_servers = {{ memcache_url }} -{% endif -%} - -[metricd] - -# -# From gnocchi -# - -# Number of workers for Gnocchi metric daemons. By default the available number -# of CPU is used. (integer value) -# Minimum value: 1 -#workers = <None> - -# How many seconds to wait between scheduling new metrics to process (integer -# value) -#metric_processing_delay = 60 - -# How many seconds to wait between metric ingestion reporting. Set value to -1 -# to disable reporting (integer value) -# Minimum value: -1 -#metric_reporting_delay = 120 - -# How many seconds to wait between cleaning of expired data (integer value) -#metric_cleanup_delay = 300 - - -[oslo_middleware] - -# -# From oslo.middleware.http_proxy_to_wsgi -# - -# Whether the application is behind a proxy or not. This determines if the -# middleware should parse the headers or not. (boolean value) -#enable_proxy_headers_parsing = false - - -[oslo_policy] - -# -# From oslo.policy -# - -# The file that defines policies. (string value) -#policy_file = policy.json - -# Default rule. Enforced when a requested rule is not found. (string value) -#policy_default_rule = default - -# Directories where policy configuration files are stored. They can be relative -# to any directory in the search path defined by the config_dir option, or -# absolute paths. The file defined by policy_file must exist for these -# directories to be searched. Missing or empty directories are ignored. (multi -# valued) -#policy_dirs = policy.d - - -[statsd] - -# -# From gnocchi -# - -# The listen IP for statsd (string value) -#host = 0.0.0.0 - -# The port for statsd (port value) -# Minimum value: 0 -# Maximum value: 65535 -#port = 8125 - -# Resource UUID to use to identify statsd in Gnocchi (unknown value) -#resource_id = <None> - -# Creator value to use to identify statsd in Gnocchi (string value) -#creator = {{ statsd.user_id }}:{{ statsd.project_id }} - -# Archive policy name to use when creating metrics (string value) -#archive_policy_name = <None> - -# Delay between flushes (floating point value) -#flush_delay = 10 - - -[storage] - -# -# From gnocchi -# - -# Storage driver to use (string value) -#driver = file - -# Ceph pool name to use. (string value) -#ceph_pool = gnocchi - -# Ceph username (ie: admin without "client." prefix). (string value) -#ceph_username = <None> - -# Ceph key (string value) -#ceph_secret = <None> - -# Ceph keyring path. (string value) -#ceph_keyring = <None> - -# Ceph configuration file. (string value) -#ceph_conffile = /etc/ceph/ceph.conf - -# Path used to store gnocchi data files. (string value) -#file_basepath = /var/lib/gnocchi - -# Swift authentication version to user. (string value) -#swift_auth_version = 1 - -# Swift pre-auth URL. (string value) -#swift_preauthurl = <None> - -# Swift auth URL. (string value) -#swift_authurl = http://localhost:8080/auth/v1.0 - -# Swift token to user to authenticate. (string value) -#swift_preauthtoken = <None> - -# Swift user. (string value) -#swift_user = admin:admin - -# Swift user domain name. (string value) -#swift_user_domain_name = Default - -# Swift key/password. (string value) -#swift_key = admin - -# Swift tenant name, only used in v2/v3 auth. (string value) -#swift_project_name = <None> - -# Swift project domain name. (string value) -#swift_project_domain_name = Default - -# Prefix to namespace metric containers. (string value) -#swift_container_prefix = gnocchi - -# Endpoint type to connect to Swift (string value) -#swift_endpoint_type = publicURL - -# Connection timeout in seconds. (integer value) -# Minimum value: 0 -#swift_timeout = 300 - -# S3 endpoint URL (string value) -#s3_endpoint_url = <None> - -# S3 region name (string value) -#s3_region_name = <None> - -# S3 access key id (string value) -#s3_access_key_id = <None> - -# S3 secret access key (string value) -#s3_secret_access_key = <None> - -# Prefix to namespace metric bucket. (string value) -#s3_bucket_prefix = gnocchi - -# Number of workers to run during adding new measures for pre-aggregation -# needs. Due to the Python GIL, 1 is usually faster, unless you have high -# latency I/O (integer value) -# Minimum value: 1 -#aggregation_workers_number = 1 - -# Coordination driver URL (string value) -#coordination_url = <None> -- GitLab