Fix api-paste.ini path in RedHat ditro install

This patch aims to revert the commit meant to
fix api-paste.ini [1] that has no effect to
solve the path problem in distro installs based
on RedHat.

After the neutron_install.yml task responsible
to install neutron role packages, some config files
are placed in /usr/share/neutron, some of these files
are soft links from /etc/neutron from /usr/share/neutron.

One of the config files that is used by neutron-server is
the api-paste.ini that needs to be placed in /etc/neutron in
order to the service to initalize correctly.

This is a workaround only for RedHat distro installs
and the root cause is still being investigated.

[1] c0b17e9d89

Change-Id: Ie5441b8d2b147bf0e57928a2b6ea6a745a96c67f
This commit is contained in:
Guilherme Steinmüller 2018-09-03 21:58:16 -03:00
parent b0241f8100
commit 1dd266d35a
2 changed files with 11 additions and 1 deletions

View File

@ -63,6 +63,16 @@
notify:
- Restart neutron services
- name: Place api-paste.ini to the correct path in RedHat
file:
src: "/usr/share/neutron/api-paste.ini"
dest: "{{ neutron_conf_dir }}/api-paste.ini"
owner: "root"
group: "{{ neutron_system_group_name }}"
mode: "0640"
state: link
when: neutron_install_method == 'distro' and ansible_os_family == 'RedHat'
- name: Preserve original configuration file(s)
command: "cp {{ item.target_f }} {{ item.target_f }}.original"
args:

View File

@ -582,7 +582,7 @@ neutron_role_project_group: neutron_all
neutron_core_files:
- tmp_f: "/tmp/api-paste.ini.original"
target_f: "{{ (neutron_install_method == 'distro' and ansible_os_family == 'RedHat') | ternary('/usr/share/neutron', neutron_conf_dir) }}/api-paste.ini"
target_f: "{{ neutron_conf_dir }}/api-paste.ini"
config_overrides: "{{ _neutron_api_paste_ini_overrides | combine(neutron_api_paste_ini_overrides, recursive=True) }}"
config_type: "ini"
- tmp_f: "/tmp/rootwrap.conf.original"