ansible-config_template/releasenotes/notes/config_template-MultiStrOps-support-c28e33fd5044e14d.yaml
Kevin Carter b42faff784
Add MultiStrOps support to config_template
This change adds the MultiStrOps variaable type to the config
template parsing as well as supports multi string options when
passing configuration overrides.

This is made prossible by using the set type for options found within
config overrides and creating a custom dictionary class that allows
for multiple keys to be stored as a set. When the config_template
encounters a set type it will process and reder value as a
MultiStrOps.

Set types are defined in yaml via the "?" entry.

Example Overrides:
  things:
    - 1
    - 2
  multistrops_things:
    ? a
    ? b

Example Rendered Config:
  things = 1,2
  multistrops_things = a
  multistrops_things = b

Change-Id: I2193ea2eb7f839c3151c2c96f9dfe86f141e5a15
Closes-Bug: #1542513
Signed-off-by: Kevin Carter <kevin.carter@rackspace.com>
2016-02-10 09:12:36 -06:00

33 lines
807 B
YAML

---
features:
- |
The ability to support MultiStrOps has been added to
the config_template action plugin. This change updates
the parser to use the ``set()`` type to determine if
values within a given key are to be rendered as
``MultiStrOps``. If an override is used in an INI
config file the set type is defined using the standard
yaml construct of "?" as the item marker.
::
# Example Override Entries
Section:
typical_list_things:
- 1
- 2
multistrops_things:
? a
? b
::
# Example Rendered Config:
[Section]
typical_list_things = 1,2
multistrops_things = a
multistrops_things = b
fixes:
- Resolves issue https://bugs.launchpad.net/openstack-ansible/+bug/1542513