Add a doc example for yaml file overrides

Adds an example for yaml config file overrides and provides
clarification that the entire yaml file contents are overwritten
by any supplied override values, not just the added or changed values.

Change-Id: Ia64b6dceace4f33617736426c7818cfb6fc101e7
Partial-Bug: 1605758
This commit is contained in:
Bob Taylor 2016-09-01 18:34:17 +00:00 committed by Jesse Pretorius (odyssey4me)
parent bb3ddb31c7
commit 7c5f177c57

View File

@ -116,6 +116,52 @@ To assist you in finding the appropriate variable name to use for
overrides, the general format for the variable name is
``<service>_policy_overrides``.
Overriding YAML files
~~~~~~~~~~~~~~~~~~~~~~~~~~
You can override ``.yml`` file values by supplying replacement YAML content.
.. note::
All default YAML file content will be completely overwritten by
the provided overrides, so the entire YAML source (both the existing
content and your changes) must be provided.
For example, you can define a meter exclusion for all hardware items
in the default content of ceilometer's ``pipeline.yml``:
.. code-block:: yaml
sources:
- name: meter_source
interval: 600
meters:
- "!hardware.*"
sinks:
- meter_sink
- name: foo_source
value: foo
You can accomplish this through the use of the following configuration
entry in ``/etc/openstack_deploy/user_variables.yml``:
.. code-block:: yaml
ceilometer_pipeline_yaml_overrides:
sources:
- name: meter_source
interval: 600
meters:
- "!hardware.*"
sinks:
- meter_sink
- name: source_foo
value: foo
To assist you in finding the appropriate variable name to use for
overrides, the general format for the variable name is
``<service>_<filename>_<file extension>_overrides``.
Currently available overrides
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~