Commit Graph

24 Commits

Author SHA1 Message Date
Guilherme Steinmüller 1f61130240 Retire openstack-ansible-os_watcher
Change-Id: I0dfd5318a7b953618673eb4ffd17f89a1cf900c4
2019-04-24 16:51:54 -04:00
Jesse Pretorius 0aed681fb8 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: Iab5c434cd40b909b8b43f52cd9f50cae83c1c715
2018-10-23 10:07:09 +01:00
Zuul 3b78c4f9d6 Merge "Trivial: Fix the pep8 warning" 2018-08-17 05:19:37 +00:00
caoyuan ffd4d551ee Use include_tasks instead of include
include is marked as deprecated since ansible 2.4[0]

Switch to include_tasks or import_playbook as necessary

[0] https://docs.ansible.com/ansible/2.4/include_module.html#deprecated

Change-Id: I144d570555780b46ed132e4895d9f640f2d95555
2018-08-15 06:28:28 +00:00
wangqi c52377c3f3 Trivial: Fix the pep8 warning
The yaml should start with "---"

Change-Id: Ia92c1536f41d2927b66a926d9fe4eecf47e1cdfd
2018-08-06 07:58:26 +00:00
Jesse Pretorius 2ab1b99446 Move MQ vhost/user creation into role
There is no record for why we implement the MQ vhost/user 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 implement two new variables:
- watcher_oslomsg_rpc_setup_host
- watcher_oslomsg_notify_setup_host

These are used in the role to allow delegation of the MQ vhost/user
setup for each type to any host, but they default to using the first
member of the applicable oslomsg host group.

We also adjust some of the defaults to automatically inherit existing
vars set in group_vars form the integrated build so that we do not
need to do the wiring in the integrated build's group vars. We still
default them in the role too for independent role usage.

Finally, we remove the test mq setup tasks and clean up any unused
or unnecessary variables configured in tests.

Change-Id: I6b781cde4e075dee9d79cf28a55eeda00460c37d
2018-07-27 12:24:39 +01:00
Andy Smith cbe8947272 Update to use oslo.messaging service for RPC and Notify
This introduces oslo.messaging variables that define the RPC and
Notify transports for the OpenStack services. These parameters replace
the rabbitmq values and are used to generate the messaging
transport_url for the service.

This patch:
* Add oslo.messaging variables for RPC and Notify to defaults
* Add transport_url generation to conf template
* Add oslo.messaging to tests inventory and update tests
* Update readme
* Install extra packages for optional drivers
* Add release note

Change-Id: Ie43bcf4c5a8414072f1917ab8b30a034a514c51b
2018-07-26 09:16:46 +00:00
Jesse Pretorius 4bffc1e91f 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: I32752523e9ed484bf0864be4db146bb333f9f55e
2018-07-14 14:43:20 +01:00
Jesse Pretorius 59acdd8c68 Move database creation into role
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 implement a new variable called 'watcher_db_setup_host'
which is used in the role to allow delegation of the database setup
task to any host, but defaults to the first member of the galera_all
host group. We also document the variable 'watcher_galera_address' which
has been used for a long time, but never documented. A bunch of unused
variables have also been removed.

Change-Id: I3b845ee913e3abc70bbc59b85142ebd55b92de51
2018-06-29 13:23:31 +00:00
Jean-Philippe Evrard 0f0e414f41 Do not log passwords
This prevents data to be leaked into the callback plugin.

Change-Id: I0929d73d0b08243b4d9fb6b13d35a0037230c409
2018-04-11 13:48:19 +02:00
Jesse Pretorius 2551756e56 Remove tests-repo-clone.sh
Now that run_tests.sh handles the tests repo clone, we can
remove the use of the older tests-repo-clone.sh script.

Change-Id: I13963ba367a0835a01a61a1cef0207dc737f2b0d
2018-03-28 10:16:54 +01:00
Zuul f2bac9630a Merge "ansible-role-requirements: Use systemd_service role from openstack namespace" 2018-03-25 17:06:52 +00:00
Jesse Pretorius ae5b90d1f5 ansible-role-requirements: Use systemd_service role from openstack namespace
In order to ensure that the updated role is used for tests,
we adjust the a-r-r file to pull from the correct repo.

Change-Id: I2c882a899722829b6c30d8c97d5334c571a0a133
2018-03-25 16:21:57 +01:00
Jesse Pretorius f5308cdc91 ansible-role-requirements: Add common python_venv_build role
In order to allow tests to work as the use of the common
role is implemented in the various roles, we pre-implement
the addition of the role into the a-r-r file.

Change-Id: Ibed29d36f32f70ae27dcecb7c409df8ccb28d6b0
Implements: blueprint python-build-install-simplification
Signed-off-by: Jesse Pretorius <jesse.pretorius@rackspace.co.uk>
2018-03-24 23:22:18 +00:00
Jesse Pretorius 66a0e3e3dd ansible-role-requirements: Add common systemd_service role
In order to allow tests to work with https://review.openstack.org/551028
merged, add the role to the a-r-r file.

Change-Id: I8e84719e5877b7a5a6efc8aea7484eae680491c6
2018-03-13 16:52:53 +00:00
OpenStack Proposal Bot 1b88cfd28a Updated from OpenStack Ansible Tests
Change-Id: Ida256ffa59cb41c8b92437eae67a639a9b92b31c
2018-02-14 20:07:41 +00:00
Jesse Pretorius b52cc7af48 Initial OSA zuul v3 role jobs
This patch implements an initial set of jobs intended to match
the current job execution method. It does not intend to improve
how the jobs are executed - only to replicate what is currently
in openstack-infra/openstack-zuul-jobs and provide the platform
to iterate on.

Change-Id: I3b72774f0859c2453e2f9b219eefbebd4b631108
2017-10-17 20:50:58 +00:00
OpenStack Proposal Bot 96b04e68d4 Updated from OpenStack Ansible Tests
Change-Id: I1796105b389b179151f481a60418ce9d5a959ddb
2017-10-12 20:45:13 +00:00
Jesse Pretorius dd906fbbaf Use zuul-cloner for tests repo in OpenStack-CI
When executing the tests repo clone in OpenStack-CI,
use zuul-cloner instead of git to enable cross-repo
testing. This ensures that if a dependent patch from
the tests repo is noted using 'Depends-On: <change-id>'
in the commit message, that patch will be included.

Depends-On: Idce7abebf32f24c356a27e099fbca954d917402b
Depends-On: I5da7802d61d2ab6b03908138e3a3ed2db22e3d29
Change-Id: I007306c47f9cc526b163c2e659baa67769affd84
2017-05-16 11:44:48 +00:00
Jesse Pretorius 1a0db2cf9a Fix role gate tests for Ansible 2.3
Add 'become' and root 'user' options to the playbook instead of using
'ansible_become' through an inventory variable.

Change-Id: I36e68b24fad5015ea02a5c92b6cd081daf81b520
2017-05-16 12:11:55 +01:00
Jesse Pretorius 00f1555bbb Use centralised test scripts
This patch consumes the test scripts implemented by
https://review.openstack.org/375061 to ensure that
the tests and test preparation is consistent and
more maintainable.

Change-Id: I15440dfae38ad9f1f6f44c5115cb08adda57e453
2016-09-28 11:38:40 +01:00
Jesse Pretorius d74a847fc6 Force Ansible to use dynamic includes
Ansible 2.1.1 introduces a regression in the way conditional
includes are handled which results in every task in the
included file being evaluated even if the condition for the
include is not met. This extends the run time significantly
for a deployment.

This patch forces all conditional includes to be dynamic.

Change-Id: I8ebc3b5f627c3f5fa1f0b20aece10e49ce6220cd
Related-Bug: https://github.com/ansible/ansible/issues/17687
2016-09-22 16:34:00 +01:00
Major Hayden 3992b860e1 Ansible 2.1.1 role testing
Co-Authored-By: Major Hayden <major@mhtx.net>
Change-Id: I850e7573a279ea317ee6743eae03e23940163453
Signed-off-by: Kevin Carter <kevin.carter@rackspace.com>
2016-09-19 15:31:35 -04:00
Michael Gugino 76a013f814 Initial commit
This is the initial commit for the watcher role.
2016-08-22 13:37:00 -04:00