Handlers are always triggered in ceph-ansible because ceph.conf file is
generated with a randomly order for the different keys/values pairs
in sections.
In python, a dict is not sorted. It means in our case each time we try
to generate the ceph.conf file it will be rendered with a random order
since the mecanism behind consist of rendering a file from a python dict
with keys/values. Therefore, as a quick workaround, forcing this dict to be
sorted before rendering the configuration file will ensure that it will be
rendered always the same way.
Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com>
ansible 2.2 deprecates first_available_file option which is used in
the config_template module by 'generate ceph configuration file' task.
This change syncs the config_module files from their master repository
in github.com/openstack/openstack/ansible-plugins which includes the fix
2f6cac2cf6
Signed-off-by: Alberto Murillo Silva <alberto.murillo.silva@intel.com>
This change allows keys in INI format to be any case.
The default ConfigParse module sets this to be lower
however in some cases keys are needed to be upper and/or
mixed.
Change-Id: I4e0dedb1b73ee596929bd425af6b0aaefd3a6c27
Signed-off-by: Kevin Carter <kevin.carter@rackspace.com>
(cherry picked from commit f946160dd0)
These changes address 2 issues:
* The config template plugin in v1 mode was not respecting a list
of integers and would cause a stacktrace because the ConfigParese
module expects everything written to be a string.
* The config template plugin in v2 mode was not properly handingly
the multi-string-op type due to an oversight in the ``_option_write``
method.
With these updates the config template is now able to better support
all of the potential options that could be thrown at it when writing
an INI config file.
Signed-off-by: Kevin Carter <kevin.carter@rackspace.com>
This change updates the config_template plugin to load
the version of the config_template needed based on the
detected version of ansible running. Note, Once the
upstream change merges for ansible 2 [0] we should
drop the ansible 2 version of this plugin.
[0] - https://github.com/ansible/ansible/pull/12555
Change-Id: Ifbdde0f30ee2bd8025ede07c86234527ba9891db
Signed-off-by: Kevin Carter <kevin.carter@rackspace.com>