Commit Graph

62 Commits

Author SHA1 Message Date
Jonathan Rosser 1b6f3273fb Use ansible_facts[] instead of fact variables
See https://github.com/ansible/ansible/issues/73654

Change-Id: I40b37608f65ec57b26fb10528da63ad54f9a1496
2021-03-16 08:02:26 +00:00
Jonathan Rosser e0afffd98c Remove references to unsupported operating systems
All references to Gentoo, SUSE, Debian stretch and Centos-7  are removed.
Conditional tasks, ternary operators and variables are simplified where possible
OS specific variables files are generalised where possible

Change-Id: I96a9757621eab69e7bc16a2e31ab28d0eb8a23be
2021-03-10 12:16:38 +00:00
Dmitriy Rabotyagov 986c8317d4 Cleanup after repo_build and pip_install retirement
Change-Id: Idbd678d13761b5ed19d856628f19bd145ba34a64
2020-05-12 21:42:32 +03:00
Dmitriy Rabotyagov bf7fe362e6 Replace git.openstack.org with opendev.org
This patch replaces git.openstack.org with opendev.org as redirection
from old path was enabled.
Also we change upper constraints url due to [1]

[1] http://lists.openstack.org/pipermail/openstack-discuss/2019-May/006478.html

Depends-On: https://review.opendev.org/693841/
Change-Id: I62dcba3a70298060baf975ac012d15e962b92863
2019-11-22 20:44:36 +00:00
melissaml 066c4025f5 Replace git.openstack.org URLs with opendev.org URLs
Change-Id: Ia06f067b5bdd9fc6c29ebd49c699d49a83d9634e
2019-07-13 20:28:24 +00:00
Jimmy McCrory 40cf1971e8 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: Ifb4cecdb003bf8e90fddcd223b7c6e08b5bc03b8
2018-10-20 15:28:29 -07:00
caoyuan 748af51690 use include_tasks instead of include
include is marked as deprecated since ansible 2.4[0]
[0] https://docs.ansible.com/ansible/2.4/include_module.html#deprecated

Change-Id: I739fc1ce789c9db68687a2d2bf20d7567cd6cd3a
2018-08-15 17:06:10 +08:00
Jesse Pretorius 682764493a Remove unnecessary MQ vhost/user creation tasks/vars
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 remove the test vars and tasks which were duplicated
as they are no longer required.

Change-Id: I7209861cd0b285ce1d641f68d2e97505cd3b1fb8
2018-07-31 23:01:59 +01:00
Zuul 5e30d6c978 Merge "Trivial: Fix the pep8 warning" 2018-07-31 06:59:30 +00:00
Jesse Pretorius 9fb3ab96a2 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.

With the dependent patches, the openstack_openrc role is now executed once
on the designated host, so it is no longer required as a meta-dependency for
the role.

Depends-On: https://review.openstack.org/579233
Depends-On: https://review.openstack.org/579959
Change-Id: I155b5036dd98f80a0d31d8bb691beae147a97bc3
2018-07-06 13:51:39 +00:00
Jesse Pretorius 2d2b3a7149 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 'designate_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 'designate_galera_address' which
has been used for a long time, but never documented. A bunch of unused
variables have also been removed.

Change-Id: Ie0d09401adaa66142fe12d1b6454641dd76104b7
2018-06-28 17:23:41 +01:00
fpxie b65faedbbe Trivial: Fix the pep8 warning
The yaml should start with "---"

Change-Id: If62ec06a8fa9459f307db296870acff4cc4b271c
2018-06-20 15:58:36 +08:00
Andrew Smith 9625cb41fc Update to use oslo.messaging services 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. The association of the messaging backend server to the
oslo.messaging service will be transparent to the designate service.

This patch:
* Add oslo.messaging variables for RPC and Notify to defaults
* Update transport_url generation (add for notification)
* Add oslo.messaging to tests inventory
* Update tests
* Add releaes note
* Update README and example playbook

Change-Id: I620a13e1ea3c24c8bd31c02206613d37d769dd30
2018-06-06 13:56:52 -04:00
Jonathan Rosser ff9a55d5db Create rndc key
The deployer can provide an rndc key to authenticate with bind.

Change-Id: I7cec53ebaf9fb69fa7116878528fa654dc362f92
2018-05-30 18:40:42 +01:00
Markos Chandras 07d79cd0a0 Add support for using distribution packages for OpenStack services
Distributions provide packages for the OpenStack services so we add
support for using these instead of the pip ones.

Change-Id: Iab155254fa3600e1b6b3e8992f7c1fdc6f710ed6
Implements: blueprint openstack-distribution-packages
2018-05-18 17:16:11 +01:00
Jesse Pretorius 47a2e5903a 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: If822729b14984ae2f654728ecf8ee528f023bffe
2018-03-28 10:13:49 +01:00
Zuul c156d8e3fb Merge "ansible-role-requirements: Use systemd_service role from openstack namespace" 2018-03-25 17:32:12 +00:00
Jesse Pretorius a45674ae9b 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: Ic4f89d564caabf6df782390adf738a6253eedcc7
2018-03-25 16:19:37 +01:00
Jesse Pretorius 45c39b136a 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: I5c8fcb9af7bcf1d0a96378ad6b29244c6f50dae0
Implements: blueprint python-build-install-simplification
Signed-off-by: Jesse Pretorius <jesse.pretorius@rackspace.co.uk>
2018-03-24 23:19:42 +00:00
Jesse Pretorius d5b0d705f5 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: Ia8dbcdb00655dab71e94fcc0c96fe6f1a06d595a
2018-03-13 16:49:53 +00:00
OpenStack Proposal Bot 0b549b919f Updated from OpenStack Ansible Tests
Change-Id: I83578da41ea2e4e29388275eec33ab87def22cfd
2018-02-14 20:05:28 +00:00
Jimmy McCrory ceb12b1088 Fix ansible-lint test failures
With the merge of https://review.openstack.org/520177 in the
tests repo some ansible-lint failures which previously were
not being picked up are now detected.

Change-Id: I2c1720056046f038cfeae3b0591230ab1aa5e5ac
2017-12-03 18:46:54 -08:00
Jesse Pretorius 0b616117fe Allow role defaults to determine the branch tested
Currently there's an override in place to make the tests
use the master branch. This becomes a pain when master
becomes a stable branch because this override is out of
the norm, so it gets forgotten.

The override is not necessary - we can just use the
values from the role defaults instead.

Change-Id: I4cf8a97ee93da9e2648cc47782e6984ab7cc13b7
2017-11-03 09:39:52 +00:00
Jean-Philippe Evrard 4fec57b838 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: Ic27fb8019ab35fbdf45e23164f907c6c6baf8655
2017-10-17 18:16:53 +00:00
Major Hayden 5dfd2bf8f9
Add dnf support
This patch adds dnf support for CentOS.

Implements: blueprint centos-and-dnf
Change-Id: Ice2477c5c44ef1e4cd87763032dda931a87ab195
2017-08-02 14:00:34 -05:00
Markos Chandras 92fb2b5284 tests: Convert bind configuration file to template
It's better to use a single template file for the bind configuration
instead of using a copy for each distribution. The new template file
is based on the configuration files from Ubuntu, CentOS and openSUSE.

Change-Id: I85ec991d4761db891c624c9495ccc97c7d08dfe3
2017-07-11 12:43:08 +01:00
OpenStack Proposal Bot 1c4d03556c Updated from OpenStack Ansible Tests
Change-Id: I55f2d1ccb5becd4fd2d11e1d13f274b20f5e0317
2017-06-22 15:19:24 +00:00
Jesse Pretorius 9d5562983c 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.

Change-Id: Ia4d7c9674d96bf1e9d4e89362892084c801f2e92
Depends-On: Idce7abebf32f24c356a27e099fbca954d917402b
2017-05-04 16:51:15 +01:00
Jean-Philippe Evrard 8904dd15f3 Standardize the testing for Designate
Follows a pattern similar to [1].

[1]: 660c5b8bae

Change-Id: I3027ebead8e64ad28c3db17daff522fd6e1f9a46
2017-04-19 15:34:39 +00:00
Tim Simmons b9adeab14f Enable current Designate services
designate-pool-manager and designate-zone-manager are deprecated
in favor of designate-worker and designate-producer. This enables
those services.

This does not functionally change the way Designate works, so the
associated config changes are minimal. This does remove some
cumbersome pool manager cache configuration that is no longer
needed, but wasn't being used anyway. It also simplifies the
Designate architecture by making the separation of duties easier
to grok, and enables simple horizontal scaling by starting more
``designate-worker`` processes.

Change-Id: I7adb2cea21136c18f36e0ed6404989d4e5de8e4d
2017-02-03 20:41:44 +00:00
Tim Simmons 69877f3437 Configure pools.yaml inside Designate role
This adds the ability for a user to configure the Designate
pools.yaml file inside of the role by specifying an attribute.

Because the data required is yaml, it's a nice mapping to specify
the yaml attribute and have it dumped directly to the pools.yaml
file.

This allows users to use attributes from other plays (perhaps setting
up some complex DNS infrastructure in their cloud) and insert them
into Designate without having to write their own template or supply
their own file.

This also invokes the `designate-manage` command to load the pools.yaml
file into the Designate database, and simplifies the tests that
do the pools.yaml needful.

Change-Id: I11a849898bf33aa6b8aa6605296ac7fd733d7c01
2017-02-02 23:04:06 +00:00
Marc Gariepy 5ba88401eb Add CentOS support for os_designate
This commit add CentOS support to os_designate

Change-Id: Idfae25a8a769348da629bc0a4a79d1ee56d60aad
2017-01-27 16:34:54 +00:00
Marc Gariepy 4921521677 standardize test for os_designate
standardize test based on other roles.

Change-Id: I3cec90ad07f1a1c64177fb3a27d97a6d0bb47f46
2017-01-26 13:55:05 -05:00
Donovan Francesco (drifterza) 7cd0b561a5 Using updated tempest method for designate api.
Change-Id: I94147366a6b7866d6de1920f72c7791eea3a243d
2016-11-22 09:57:55 +02:00
Donovan Francesco (drifterza) c476e8284a Updating designate role to align with integrated repo.
- Variables for designate_galera_password:
 - Variables for designate_pool_manager_galera_password:

Change-Id: Ieb45a4c9813fe5106afe2c560ff9c19a73b43f72
Closes-Bug: #1641600
2016-11-16 16:43:24 +02:00
Deepak 0f286a07a9 Update test-vars.yml for repositories
Renamed in os_designate role repo
Changed test-vars.yml to os_designate-overrides.yml
Removed the test-vars.yml file

Change-Id: Ic3d5c3094d96cf0026564fcc8407157dfc87cec4
Partial-Bug: #1629284
2016-10-05 22:04:34 +05:30
Jesse Pretorius 32aff27542 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: I3a50b32bbb7bf724ccc446876755454b5cb24c89
2016-09-27 18:41:22 +01:00
Jesse Pretorius 12d56f37ca 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: Iea4689aa17b232911275d9a51cfbd5713b78a557
Related-Bug: https://github.com/ansible/ansible/issues/17687
2016-09-22 12:38:16 +01:00
Travis Truman 4c40547818 Ansible 2.1.1 role testing
Change-Id: I2db8435b0ae5b6004ebe1985c5606c0c39900a95
Signed-off-by: Kevin Carter <kevin.carter@rackspace.com>
2016-09-19 15:21:37 -04:00
Jenkins 0e8ba62e2f Merge "Support service-specific rabbitmq clusters" 2016-07-22 21:53:57 +00:00
Jimmy McCrory 33e47f76b0 Remove openstack_hosts from test requirements
The openstack_hosts role is not used in any of the test playbooks
or required by dependent roles and can be removed from the test
role requirements.

Change-Id: I64df0427e7e9bf7f76d377f0caeeda7e814caa37
2016-07-20 18:47:01 -07:00
Travis Truman 311af8a571 Support service-specific rabbitmq clusters
All rabbitmq connection vars are now namespaced. Namespace support
was previously inconsistent which limited deployer override options.

Change-Id: I2593239e98aa3ebd578d030206299d4868d036ca
Implements: blueprint multi-rabbitmq-clusters
2016-07-18 10:36:54 -04:00
Travis Truman 0d123e90ce Only install to virtual environment
Remove all tasks and variables related to toggling between installation
of designate inside or outside of a Python virtual environment.
Installing within a venv is now the only supported deployment.

Additionally, a few changes have been made to make the creation of the
venv more resistant to interruptions during a run of the role.
* unarchiving a pre-built venv will now also occur when the venv
  directory is created, not only after being downloaded
* virtualenv-tools is run against both pre-built and non pre-built venvs
  to account for interruptions during or prior to unarchiving

Change-Id: If3f0cb96d0ac670f6c53243283d6726067cba011
Implements: blueprint only-install-venvs
2016-07-08 12:58:36 -04:00
Jesse Pretorius 2da87369ba Clean up container cache prep in tests
This patch cleans up the container cache preparation in the tests
due to the following patches:

- https://review.openstack.org/307856 (new image build process)
- https://review.openstack.org/315114 (new apt config process)
- https://review.openstack.org/322188 (new resolver config process)

Change-Id: I2999f20048903bd55972e89df95cd2b90b0f1715
2016-06-17 18:32:19 +01:00
Jimmy McCrory 9985d50ad6 Remove pip_lock_down dependency
The pip_install and pip_lock_down roles have been merged.

Remove pip_lock_down from the role's meta dependencies and test
requirements.

Change-Id: I4c5f51143d783d8acd0a6ef9fc0d12deaab182ec
2016-06-14 15:57:08 -07:00
Jimmy McCrory a7dbf1c21c Add missing zone-manager service
Update documentation, default variables, tasks, and environment
inventory to include installation of the designate-zone-manager service.

Change-Id: I1a72cad13e88d962a1e38793a1a3b5b35c0ba8b7
2016-06-14 15:27:50 -07:00
Matt Thompson 6d5f75f025 Test designate w/ designate tempest plugins
This commit updates role to install tempest and
designate-tempest-plugin and then runs the designate scenario tests.

Change-Id: Icc70b47e8cc34d21ef082e7dd04d969789c9ca83
2016-05-25 20:12:35 +01:00
Jesse Pretorius 223347b9c1 Remove py_from_git role
The py_from_git role is removed as it is no longer required.

Change-Id: I4420e93fbeb4244e55c5dc2c1c48222bc3530ae4
2016-05-04 09:11:16 +01:00
Matt Thompson c29b2d8d03 Remove bind9 and add functional tests
This commit moves the installation of bind9 to the tests, leaving the
installation/configuration of the desired DNS server to the deployer.
We can eventually use a role to handle the installation/configuration
of bind, but some further research will need to be done to isolate
the best role.

Additionally, this commit adds some very basic tests that validate the
Designate API.  Next steps involve using designate-tempest-plugin to
handle this.

NOTE: No relnote is being added for the removal of bind9 as no valid
      configuration was being dropped for bind9, meaning we had a
      non-functional DNS server as far as designate was concerned.

Change-Id: I5a21e32f8ad885afd5b4a04d2ef348cd65d0999b
2016-04-21 17:35:47 +01:00
Jesse Pretorius 5d5e2a3d8b Switch defaults/tests to use master branch
Change-Id: I7e7cf1e514ad717b7f64d11e466932a54708f480
2016-04-03 12:58:41 +01:00