From a3dfdfc085d406c8a508c3a79acb4ef2872dbc02 Mon Sep 17 00:00:00 2001
From: Bertrand Lallau <bertrand.lallau@thalesgroup.com>
Date: Thu, 13 Apr 2017 17:38:12 +0200
Subject: [PATCH] Simplify Openstack services configuration possibilities

Actually Openstack services configuration can be overriden using many
files:
- /etc/kolla/config/<< service name >>/<< config file >>
- /etc/kolla/config/<< service name >>/<<host>>/<< config file >>
- /etc/kolla/config/global.conf
- /etc/kolla/config/database.conf
- /etc/kolla/config/messaging.conf

Only per-service configuration is actually documented here:
https://github.com/openstack/kolla-ansible/blob/master/doc/advanced-configuration.rst#L164

Allowing to globally modify service configuration can be perform too,
but it can be done in 3 different manners, all not documented:
- /etc/kolla/config/global.conf
- /etc/kolla/config/database.conf
- /etc/kolla/config/messaging.conf

database.conf and messaging.conf seems redundant with global.conf.
In order to simplify codebase it seems logical to remove them.

Documentation has been added for overriding configuration globally and
release note has been added too.

Closes-Bug: #1682479
Change-Id: I5d922dfc0d938173bad34ac64e490b78db1b7e31
---
 ansible/roles/aodh/tasks/config.yml                   |  2 --
 ansible/roles/barbican/tasks/config.yml               |  2 --
 ansible/roles/ceilometer/tasks/config.yml             |  2 --
 ansible/roles/cinder/tasks/config.yml                 |  2 --
 ansible/roles/cloudkitty/tasks/config.yml             |  2 --
 ansible/roles/congress/tasks/config.yml               |  2 --
 ansible/roles/designate/tasks/config.yml              |  2 --
 ansible/roles/freezer/tasks/config.yml                |  2 --
 ansible/roles/glance/tasks/config.yml                 |  2 --
 ansible/roles/gnocchi/tasks/config.yml                |  2 --
 ansible/roles/heat/tasks/config.yml                   |  2 --
 ansible/roles/ironic/tasks/config.yml                 |  4 ----
 ansible/roles/karbor/tasks/config.yml                 |  2 --
 ansible/roles/keystone/tasks/config.yml               |  2 --
 ansible/roles/kuryr/tasks/config.yml                  |  2 --
 ansible/roles/magnum/tasks/config.yml                 |  2 --
 ansible/roles/manila/tasks/config.yml                 |  4 ----
 ansible/roles/mistral/tasks/config.yml                |  2 --
 ansible/roles/murano/tasks/config.yml                 |  2 --
 ansible/roles/neutron/tasks/config-neutron-fake.yml   |  2 --
 ansible/roles/neutron/tasks/config.yml                |  2 --
 ansible/roles/nova/tasks/config-nova-fake.yml         |  2 --
 ansible/roles/nova/tasks/config.yml                   |  2 --
 ansible/roles/octavia/tasks/config.yml                |  2 --
 ansible/roles/panko/tasks/config.yml                  |  2 --
 ansible/roles/sahara/tasks/config.yml                 |  2 --
 ansible/roles/searchlight/tasks/config.yml            |  1 -
 ansible/roles/senlin/tasks/config.yml                 |  2 --
 ansible/roles/solum/tasks/config.yml                  |  2 --
 ansible/roles/tacker/tasks/config.yml                 |  2 --
 ansible/roles/trove/tasks/config.yml                  |  2 --
 ansible/roles/watcher/tasks/config.yml                |  2 --
 ansible/roles/zun/tasks/config.yml                    |  2 --
 doc/source/user/advanced-configuration.rst            | 11 +++++++++++
 ...ify-global-config-generation-8f42cea604ba1cf2.yaml |  6 ++++++
 35 files changed, 17 insertions(+), 69 deletions(-)
 create mode 100644 releasenotes/notes/simplify-global-config-generation-8f42cea604ba1cf2.yaml

diff --git a/ansible/roles/aodh/tasks/config.yml b/ansible/roles/aodh/tasks/config.yml
index 051e15076..36565fcbf 100644
--- a/ansible/roles/aodh/tasks/config.yml
+++ b/ansible/roles/aodh/tasks/config.yml
@@ -31,8 +31,6 @@
     sources:
       - "{{ role_path }}/templates/aodh.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/aodh.conf"
       - "{{ node_custom_config }}/aodh/{{ item.key }}.conf"
       - "{{ node_custom_config }}/aodh/{{ inventory_hostname }}/aodh.conf"
diff --git a/ansible/roles/barbican/tasks/config.yml b/ansible/roles/barbican/tasks/config.yml
index d3309b845..04449c2b4 100644
--- a/ansible/roles/barbican/tasks/config.yml
+++ b/ansible/roles/barbican/tasks/config.yml
@@ -67,8 +67,6 @@
     sources:
       - "{{ role_path }}/templates/barbican.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/barbican.conf"
       - "{{ node_custom_config }}/barbican/{{ item.key }}.conf"
       - "{{ node_custom_config }}/barbican/{{ inventory_hostname }}/barbican.conf"
diff --git a/ansible/roles/ceilometer/tasks/config.yml b/ansible/roles/ceilometer/tasks/config.yml
index 8d8783edf..23664fd6d 100644
--- a/ansible/roles/ceilometer/tasks/config.yml
+++ b/ansible/roles/ceilometer/tasks/config.yml
@@ -30,8 +30,6 @@
     sources:
       - "{{ role_path }}/templates/ceilometer.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/ceilometer.conf"
       - "{{ node_custom_config }}/ceilometer/{{ item.key }}.conf"
       - "{{ node_custom_config }}/ceilometer/{{ inventory_hostname }}/ceilometer.conf"
diff --git a/ansible/roles/cinder/tasks/config.yml b/ansible/roles/cinder/tasks/config.yml
index d1e6db03d..59b2ff225 100644
--- a/ansible/roles/cinder/tasks/config.yml
+++ b/ansible/roles/cinder/tasks/config.yml
@@ -48,8 +48,6 @@
     sources:
       - "{{ role_path }}/templates/cinder.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/cinder.conf"
       - "{{ node_custom_config }}/cinder/{{ item.key }}.conf"
       - "{{ node_custom_config }}/cinder/{{ inventory_hostname }}/cinder.conf"
diff --git a/ansible/roles/cloudkitty/tasks/config.yml b/ansible/roles/cloudkitty/tasks/config.yml
index 4b04cffed..d5616a750 100644
--- a/ansible/roles/cloudkitty/tasks/config.yml
+++ b/ansible/roles/cloudkitty/tasks/config.yml
@@ -29,8 +29,6 @@
     sources:
       - "{{ role_path }}/templates/cloudkitty.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/cloudkitty.conf"
       - "{{ node_custom_config }}/cloudkitty/{{ item.key }}.conf"
       - "{{ node_custom_config }}/cloudkitty/{{ inventory_hostname }}/cloudkitty.conf"
diff --git a/ansible/roles/congress/tasks/config.yml b/ansible/roles/congress/tasks/config.yml
index b8ee831a4..f8293f68a 100644
--- a/ansible/roles/congress/tasks/config.yml
+++ b/ansible/roles/congress/tasks/config.yml
@@ -26,8 +26,6 @@
     sources:
       - "{{ role_path }}/templates/congress.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/congress.conf"
       - "{{ node_custom_config }}/congress/{{ item.key }}.conf"
       - "{{ node_custom_config }}/congress/{{ inventory_hostname }}/congress.conf"
diff --git a/ansible/roles/designate/tasks/config.yml b/ansible/roles/designate/tasks/config.yml
index cbe226f22..7be261995 100644
--- a/ansible/roles/designate/tasks/config.yml
+++ b/ansible/roles/designate/tasks/config.yml
@@ -33,8 +33,6 @@
     sources:
       - "{{ role_path }}/templates/designate.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/designate.conf"
       - "{{ node_custom_config }}/designate/{{ item.key }}.conf"
       - "{{ node_custom_config }}/designate/{{ inventory_hostname }}/designate.conf"
diff --git a/ansible/roles/freezer/tasks/config.yml b/ansible/roles/freezer/tasks/config.yml
index e455be67c..832bdd18c 100644
--- a/ansible/roles/freezer/tasks/config.yml
+++ b/ansible/roles/freezer/tasks/config.yml
@@ -40,8 +40,6 @@
     sources:
       - "{{ role_path }}/templates/freezer-api.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/freezer.conf"
       - "{{ node_custom_config }}/freezer/{{ item.key }}.conf"
       - "{{ node_custom_config }}/freezer/{{ inventory_hostname }}/{{ item.key }}.conf"
diff --git a/ansible/roles/glance/tasks/config.yml b/ansible/roles/glance/tasks/config.yml
index 612ebcabb..8f4e3a813 100644
--- a/ansible/roles/glance/tasks/config.yml
+++ b/ansible/roles/glance/tasks/config.yml
@@ -29,8 +29,6 @@
     sources:
       - "{{ role_path }}/templates/{{ item.key }}.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/glance.conf"
       - "{{ node_custom_config }}/glance/{{ item.key }}.conf"
       - "{{ node_custom_config }}/glance/{{ inventory_hostname }}/{{ item.key }}.conf"
diff --git a/ansible/roles/gnocchi/tasks/config.yml b/ansible/roles/gnocchi/tasks/config.yml
index 56d20a3c8..5c49e3184 100644
--- a/ansible/roles/gnocchi/tasks/config.yml
+++ b/ansible/roles/gnocchi/tasks/config.yml
@@ -30,8 +30,6 @@
     sources:
       - "{{ role_path }}/templates/gnocchi.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/gnocchi.conf"
       - "{{ node_custom_config }}/gnocchi/{{ item.key }}.conf"
       - "{{ node_custom_config }}/gnocchi/{{ inventory_hostname }}/gnocchi.conf"
diff --git a/ansible/roles/heat/tasks/config.yml b/ansible/roles/heat/tasks/config.yml
index 63fc5ed31..4a5e4276f 100644
--- a/ansible/roles/heat/tasks/config.yml
+++ b/ansible/roles/heat/tasks/config.yml
@@ -37,8 +37,6 @@
     sources:
       - "{{ role_path }}/templates/heat.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/heat.conf"
       - "{{ node_custom_config }}/heat/{{ item.key }}.conf"
       - "{{ node_custom_config }}/heat/{{ inventory_hostname }}/heat.conf"
diff --git a/ansible/roles/ironic/tasks/config.yml b/ansible/roles/ironic/tasks/config.yml
index 417a9b42f..fd51d76b9 100644
--- a/ansible/roles/ironic/tasks/config.yml
+++ b/ansible/roles/ironic/tasks/config.yml
@@ -29,8 +29,6 @@
     sources:
       - "{{ role_path }}/templates/ironic.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/ironic.conf"
       - "{{ node_custom_config }}/ironic/{{ item }}.conf"
       - "{{ node_custom_config }}/ironic/{{ inventory_hostname }}/ironic.conf"
@@ -46,8 +44,6 @@
     sources:
       - "{{ role_path }}/templates/ironic-inspector.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/ironic-inspector.conf"
       - "{{ node_custom_config }}/ironic-inspector/inspector.conf"
       - "{{ node_custom_config }}/ironic-inspector/{{ inventory_hostname }}/inspector.conf"
diff --git a/ansible/roles/karbor/tasks/config.yml b/ansible/roles/karbor/tasks/config.yml
index db72fd192..09dd01298 100644
--- a/ansible/roles/karbor/tasks/config.yml
+++ b/ansible/roles/karbor/tasks/config.yml
@@ -30,8 +30,6 @@
     sources:
       - "{{ role_path }}/templates/karbor.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/karbor.conf"
       - "{{ node_custom_config }}/karbor/{{ item.key }}.conf"
       - "{{ node_custom_config }}/karbor/{{ inventory_hostname }}/karbor.conf"
diff --git a/ansible/roles/keystone/tasks/config.yml b/ansible/roles/keystone/tasks/config.yml
index 285df59f7..8fcf529de 100644
--- a/ansible/roles/keystone/tasks/config.yml
+++ b/ansible/roles/keystone/tasks/config.yml
@@ -40,8 +40,6 @@
     sources:
       - "{{ role_path }}/templates/keystone.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/keystone.conf"
       - "{{ node_custom_config }}/keystone/{{ item.key }}.conf"
       - "{{ node_custom_config }}/keystone/{{ inventory_hostname }}/keystone.conf"
diff --git a/ansible/roles/kuryr/tasks/config.yml b/ansible/roles/kuryr/tasks/config.yml
index 2148780bb..dd596b372 100644
--- a/ansible/roles/kuryr/tasks/config.yml
+++ b/ansible/roles/kuryr/tasks/config.yml
@@ -28,8 +28,6 @@
     sources:
       - "{{ role_path }}/templates/kuryr.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/kuryr.conf"
       - "{{ node_custom_config }}/kuryr/{{ item.key }}.conf"
       - "{{ node_custom_config }}/kuryr/{{ inventory_hostname }}/{{ item.key }}.conf"
diff --git a/ansible/roles/magnum/tasks/config.yml b/ansible/roles/magnum/tasks/config.yml
index 232099b6c..e4718ac54 100644
--- a/ansible/roles/magnum/tasks/config.yml
+++ b/ansible/roles/magnum/tasks/config.yml
@@ -29,8 +29,6 @@
     sources:
       - "{{ role_path }}/templates/magnum.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/magnum.conf"
       - "{{ node_custom_config }}/magnum/{{ item.key }}.conf"
       - "{{ node_custom_config }}/magnum/{{ inventory_hostname }}/magnum.conf"
diff --git a/ansible/roles/manila/tasks/config.yml b/ansible/roles/manila/tasks/config.yml
index 4d730cd7c..c280347bb 100644
--- a/ansible/roles/manila/tasks/config.yml
+++ b/ansible/roles/manila/tasks/config.yml
@@ -28,8 +28,6 @@
     sources:
       - "{{ role_path }}/templates/manila.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/manila.conf"
       - "{{ node_custom_config }}/manila/{{ item.key }}.conf"
       - "{{ node_custom_config }}/manila/{{ inventory_hostname }}/manila.conf"
@@ -54,8 +52,6 @@
       - "{{ role_path }}/templates/manila.conf.j2"
       - "{{ role_path }}/templates/manila-share.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/manila.conf"
       - "{{ node_custom_config }}/{{ item }}.conf"
       - "{{ node_custom_config }}/manila/{{ item }}.conf"
diff --git a/ansible/roles/mistral/tasks/config.yml b/ansible/roles/mistral/tasks/config.yml
index 73f6c6fb7..cdbd12ece 100644
--- a/ansible/roles/mistral/tasks/config.yml
+++ b/ansible/roles/mistral/tasks/config.yml
@@ -26,8 +26,6 @@
     sources:
       - "{{ role_path }}/templates/mistral.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/mistral.conf"
       - "{{ node_custom_config }}/mistral/{{ item.key }}.conf"
       - "{{ node_custom_config }}/mistral/{{ inventory_hostname }}/mistral.conf"
diff --git a/ansible/roles/murano/tasks/config.yml b/ansible/roles/murano/tasks/config.yml
index da754df81..c1e2a7624 100644
--- a/ansible/roles/murano/tasks/config.yml
+++ b/ansible/roles/murano/tasks/config.yml
@@ -23,8 +23,6 @@
     sources:
       - "{{ role_path }}/templates/murano.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/murano.conf"
       - "{{ node_custom_config }}/murano/{{ item }}.conf"
       - "{{ node_custom_config }}/murano/{{ inventory_hostname }}/murano.conf"
diff --git a/ansible/roles/neutron/tasks/config-neutron-fake.yml b/ansible/roles/neutron/tasks/config-neutron-fake.yml
index 745566f69..6736d94ca 100644
--- a/ansible/roles/neutron/tasks/config-neutron-fake.yml
+++ b/ansible/roles/neutron/tasks/config-neutron-fake.yml
@@ -24,8 +24,6 @@
     sources:
       - "{{ role_path }}/templates/neutron.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/neutron.conf"
       - "{{ node_custom_config }}/neutron/{{ item }}.conf"
       - "{{ node_custom_config }}/neutron/{{ inventory_hostname }}/neutron.conf"
diff --git a/ansible/roles/neutron/tasks/config.yml b/ansible/roles/neutron/tasks/config.yml
index 766eb471f..8245cdf15 100644
--- a/ansible/roles/neutron/tasks/config.yml
+++ b/ansible/roles/neutron/tasks/config.yml
@@ -52,8 +52,6 @@
     sources:
       - "{{ role_path }}/templates/neutron.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/neutron.conf"
       - "{{ node_custom_config }}/neutron/{{ item.key }}.conf"
       - "{{ node_custom_config }}/neutron/{{ inventory_hostname }}/neutron.conf"
diff --git a/ansible/roles/nova/tasks/config-nova-fake.yml b/ansible/roles/nova/tasks/config-nova-fake.yml
index 5a7ccd14c..d005cdc94 100644
--- a/ansible/roles/nova/tasks/config-nova-fake.yml
+++ b/ansible/roles/nova/tasks/config-nova-fake.yml
@@ -23,8 +23,6 @@
     sources:
       - "{{ role_path }}/templates/nova.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/nova.conf"
       - "{{ node_custom_config }}/nova/{{ item }}.conf"
       - "{{ node_custom_config }}/nova/{{ inventory_hostname }}/nova.conf"
diff --git a/ansible/roles/nova/tasks/config.yml b/ansible/roles/nova/tasks/config.yml
index 2af2fded2..f540f0698 100644
--- a/ansible/roles/nova/tasks/config.yml
+++ b/ansible/roles/nova/tasks/config.yml
@@ -50,8 +50,6 @@
     sources:
       - "{{ role_path }}/templates/nova.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/nova.conf"
       - "{{ node_custom_config }}/nova/{{ item.key }}.conf"
       - "{{ node_custom_config }}/nova/{{ inventory_hostname }}/nova.conf"
diff --git a/ansible/roles/octavia/tasks/config.yml b/ansible/roles/octavia/tasks/config.yml
index 93db2bcb3..87acabb6f 100644
--- a/ansible/roles/octavia/tasks/config.yml
+++ b/ansible/roles/octavia/tasks/config.yml
@@ -28,8 +28,6 @@
     sources:
       - "{{ role_path }}/templates/octavia.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/octavia.conf"
       - "{{ node_custom_config }}/octavia/{{ item.key }}.conf"
       - "{{ node_custom_config }}/octavia/{{ inventory_hostname }}/octavia.conf"
diff --git a/ansible/roles/panko/tasks/config.yml b/ansible/roles/panko/tasks/config.yml
index bb5741331..581f85e25 100644
--- a/ansible/roles/panko/tasks/config.yml
+++ b/ansible/roles/panko/tasks/config.yml
@@ -28,8 +28,6 @@
     sources:
       - "{{ role_path }}/templates/panko.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/panko.conf"
       - "{{ node_custom_config }}/panko/{{ item.key }}.conf"
       - "{{ node_custom_config }}/panko/{{ inventory_hostname }}/{{ item.key }}.conf"
diff --git a/ansible/roles/sahara/tasks/config.yml b/ansible/roles/sahara/tasks/config.yml
index 64c6990e3..fdca318b1 100644
--- a/ansible/roles/sahara/tasks/config.yml
+++ b/ansible/roles/sahara/tasks/config.yml
@@ -29,8 +29,6 @@
     sources:
       - "{{ role_path }}/templates/sahara.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/sahara.conf"
       - "{{ node_custom_config }}/sahara/{{ item.key }}.conf"
       - "{{ node_custom_config }}/sahara/{{ inventory_hostname }}/sahara.conf"
diff --git a/ansible/roles/searchlight/tasks/config.yml b/ansible/roles/searchlight/tasks/config.yml
index 717521f68..129693d8f 100644
--- a/ansible/roles/searchlight/tasks/config.yml
+++ b/ansible/roles/searchlight/tasks/config.yml
@@ -26,7 +26,6 @@
     sources:
       - "{{ role_path }}/templates/searchlight.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/searchlight.conf"
       - "{{ node_custom_config }}/searchlight/{{ inventory_hostname }}/searchlight.conf"
     dest: "{{ node_config_directory }}/{{ item.key }}/searchlight.conf"
diff --git a/ansible/roles/senlin/tasks/config.yml b/ansible/roles/senlin/tasks/config.yml
index e4442ec4f..fe50e6f78 100644
--- a/ansible/roles/senlin/tasks/config.yml
+++ b/ansible/roles/senlin/tasks/config.yml
@@ -29,8 +29,6 @@
     sources:
       - "{{ role_path }}/templates/senlin.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/senlin.conf"
       - "{{ node_custom_config }}/senlin/{{ item.key }}.conf"
       - "{{ node_custom_config }}/senlin/{{ inventory_hostname }}/senlin.conf"
diff --git a/ansible/roles/solum/tasks/config.yml b/ansible/roles/solum/tasks/config.yml
index 7df07c41b..1061f1685 100644
--- a/ansible/roles/solum/tasks/config.yml
+++ b/ansible/roles/solum/tasks/config.yml
@@ -31,8 +31,6 @@
     sources:
       - "{{ role_path }}/templates/solum.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/solum.conf"
       - "{{ node_custom_config }}/solum/{{ item.key }}.conf"
       - "{{ node_custom_config }}/solum/{{ inventory_hostname }}/solum.conf"
diff --git a/ansible/roles/tacker/tasks/config.yml b/ansible/roles/tacker/tasks/config.yml
index 6702bcd20..df1d20f00 100644
--- a/ansible/roles/tacker/tasks/config.yml
+++ b/ansible/roles/tacker/tasks/config.yml
@@ -29,8 +29,6 @@
     sources:
       - "{{ role_path }}/templates/tacker.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/tacker.conf"
       - "{{ node_custom_config }}/tacker/{{ item.key }}.conf"
       - "{{ node_custom_config }}/tacker/{{ inventory_hostname }}/tacker.conf"
diff --git a/ansible/roles/trove/tasks/config.yml b/ansible/roles/trove/tasks/config.yml
index a05f5eaad..8cb2473d3 100644
--- a/ansible/roles/trove/tasks/config.yml
+++ b/ansible/roles/trove/tasks/config.yml
@@ -42,8 +42,6 @@
     sources:
       - "{{ role_path }}/templates/trove.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/trove.conf"
       - "{{ node_custom_config }}/trove/{{ item.key }}.conf"
       - "{{ node_custom_config }}/trove/{{ inventory_hostname }}/trove.conf"
diff --git a/ansible/roles/watcher/tasks/config.yml b/ansible/roles/watcher/tasks/config.yml
index d9d0858b6..5b06d602f 100644
--- a/ansible/roles/watcher/tasks/config.yml
+++ b/ansible/roles/watcher/tasks/config.yml
@@ -30,8 +30,6 @@
     sources:
       - "{{ role_path }}/templates/watcher.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/watcher.conf"
       - "{{ node_custom_config }}/watcher/{{ item.key }}.conf"
       - "{{ node_custom_config }}/watcher/{{ inventory_hostname }}/watcher.conf"
diff --git a/ansible/roles/zun/tasks/config.yml b/ansible/roles/zun/tasks/config.yml
index 7dca74168..5787f3e39 100644
--- a/ansible/roles/zun/tasks/config.yml
+++ b/ansible/roles/zun/tasks/config.yml
@@ -27,8 +27,6 @@
     sources:
       - "{{ role_path }}/templates/zun.conf.j2"
       - "{{ node_custom_config }}/global.conf"
-      - "{{ node_custom_config }}/database.conf"
-      - "{{ node_custom_config }}/messaging.conf"
       - "{{ node_custom_config }}/zun.conf"
       - "{{ node_custom_config }}/zun/{{ item.key }}.conf"
       - "{{ node_custom_config }}/zun/{{ inventory_hostname }}/zun.conf"
diff --git a/doc/source/user/advanced-configuration.rst b/doc/source/user/advanced-configuration.rst
index 0b97bff6b..05112494d 100644
--- a/doc/source/user/advanced-configuration.rst
+++ b/doc/source/user/advanced-configuration.rst
@@ -181,6 +181,17 @@ on host myhost, the operator needs to create file
    [DEFAULT]
    ram_allocation_ratio = 5.0
 
+Kolla allows the operator to override configuration globally for all services.
+It will look for a file called ``/etc/kolla/config/global.conf``.
+
+For example to modify database pool size connection for all services, the
+operator needs to create ``/etc/kolla/config/global.conf`` with content:
+
+::
+
+   [database]
+   max_pool_size = 100
+
 The operator can make these changes after services were already deployed by
 using following command:
 
diff --git a/releasenotes/notes/simplify-global-config-generation-8f42cea604ba1cf2.yaml b/releasenotes/notes/simplify-global-config-generation-8f42cea604ba1cf2.yaml
new file mode 100644
index 000000000..8e0c9e73d
--- /dev/null
+++ b/releasenotes/notes/simplify-global-config-generation-8f42cea604ba1cf2.yaml
@@ -0,0 +1,6 @@
+---
+upgrade:
+  - |
+    The following files /etc/kolla/config/database.conf and /etc/kolla/config/messaging.conf
+    used to generate Openstack services config files are redundant with /etc/kolla/config/global.conf.
+    They have been removed in order to simplify codebase.
-- 
GitLab