From b44b828526533f12ee0ea5d12bbf98ee07403d57 Mon Sep 17 00:00:00 2001 From: Jesse Pretorius Date: Fri, 1 Jun 2018 18:08:20 +0100 Subject: [PATCH] Move database creation into role (neutron) There is no record for why we implement the database creation outside of the role in the playbook, when we could do it inside the role. Implementing it inside the role allows us to reduce the quantity of group_vars duplicated from the role, and allows us to better document the required variables in the role. The delegation can still be done as it is done in the playbook too. In this patch we remove the group_vars which were duplicated from the role, and remove the DB setup tasks as they are no longer required. Change-Id: I95971cc58aedfaf88cc209e81aa1848b9e6990f6 Depends-On: https://review.openstack.org/571781 --- inventory/group_vars/neutron_all.yml | 4 ---- playbooks/os-neutron-install.yml | 10 ---------- 2 files changed, 14 deletions(-) diff --git a/inventory/group_vars/neutron_all.yml b/inventory/group_vars/neutron_all.yml index 9675eed92e..e224242f9a 100644 --- a/inventory/group_vars/neutron_all.yml +++ b/inventory/group_vars/neutron_all.yml @@ -41,10 +41,6 @@ neutron_ceilometer_enabled: "{{ hostvars['localhost']['neutron_ceilometer_enable neutron_dns_domain: "{{ dhcp_domain }}" neutron_service_in_ldap: "{{ service_ldap_backend_enabled }}" -neutron_galera_user: neutron -neutron_galera_database: neutron -neutron_galera_address: "{{ galera_address }}" - # Ensure that the package state matches the global setting neutron_package_state: "{{ package_state }}" diff --git a/playbooks/os-neutron-install.yml b/playbooks/os-neutron-install.yml index 25fe5f2139..dc623f75be 100644 --- a/playbooks/os-neutron-install.yml +++ b/playbooks/os-neutron-install.yml @@ -81,16 +81,6 @@ - groups[oslomsg_notify_host_group] | length > 0 run_once: yes - - name: Configure MySQL user - include: common-tasks/mysql-db-user.yml - static: no - vars: - user_name: "{{ neutron_galera_user }}" - password: "{{ neutron_container_mysql_password }}" - login_host: "{{ neutron_galera_address }}" - db_name: "{{ neutron_galera_database }}" - run_once: yes - - name: Install neutron server