5 Commits

Author SHA1 Message Date
Jimmy McCrory
24cb41d08f Set container_name as host_var in test inventory
The connection plugin no longer falls back on using the
inventory_hostname as the container_name. Set container_name as a host
var for each container in the test inventory.

Change-Id: I1bf946bd8a9341c9d5030affac5779cbcbe94be6
2018-10-20 15:28:29 -07:00
Jesse Pretorius
3bd96fecbf Execute service setup against a delegated host using Ansible built-in modules
In order to reduce the packages required to pip install on to the hosts,
we allow the service setup to be delegated to a specific host, defaulting
to the deploy host. We also switch as many tasks as possible to using the
built-in Ansible modules which make use of the shade library.

The 'virtualenv' package is now installed appropriately by the openstack_hosts
role, so there's no need to install it any more. The 'httplib2' package is a
legacy Ansible requirement for the get_url/get_uri module which is no longer
needed. The keystone client library is not required any more now that we're
using the upstream modules. As there are no required packages left, the task
to install them is also removed.

Change-Id: I2e33c4cb468e93259860b600719d87c4022d6805
2018-07-12 18:15:37 +01:00
Jesse Pretorius
afe63f6f19 Resolve migration issues
A run_once task decides on a host without the
context of conditionals related to the task.
The filter is done prior to evaluating any
conditionals.

Also, only the neutron-server neutron.conf has
the database connection credentials as a
security measure, so it is not able to execute
the database migrations.

This patch ensures that the database migrations
are only run once, but are also executed
wherever neutron-server is. It also adds
multiple instances of neutron-server and
neutron-agents to better test against problems
of this nature happening again.

Additionally, the patch uses the handlers for
the offline migrations to ensure that
neutron-server is only restarted once when a
new tag is deployed.

Change-Id: I672ceb0848415c8f2653ebc8f7556db77f7f001c
2017-06-22 19:24:03 +01:00
Jimmy McCrory
c8fa21215d Fix role gate tests for Ansible 2.3
'ansible_become' defined as a host_var or in the inventory for a host
has a higher precedence than 'become' defined within a playbook.

In change Id5b76a87809f03951c954fc3d752419a673403f7, 'become' was
defined explicitly for each play running against localhost so
'ansible_become' should be removed from its host_vars.

Change-Id: Ic739c776dfb050e18828f2908f9fc1acc02bd90c
2017-04-20 10:31:10 -07:00
Andy McCrae
58bf83cd4c Use openstack-ansible-tests and ansible 2.1.1
This PR incorporates the openstack-ansible-tests bits into
openstack-ansible-os_neutron as well as adjusting the settings to use
ansible 2.1.1.

Change-Id: I7174b920f20488a5e1d514a8f32754bb95bb60de
Co-Authored-By: Travis Truman <travis_truman@cable.comcast.com>
2016-09-22 14:33:03 +01:00