63 Commits

Author SHA1 Message Date
Travis Truman
9f281faa84 Ansible 2.1.x role testing
Change-Id: I2c4ee100870f10b132d392ced5bb8783fd878863
2016-09-12 14:54:15 -04:00
Jesse Pretorius
6c33995f3b Compress test execution logs
The volume of logs we collect in CI jobs are extensive. This
patch ensures that the logs collected are compressed to reduce
the space taken in CI systems.

PYTHONUNBUFFERED is also set to ensure that the console log
from the CI jobs is recorded in the exact order of execution.

Change-Id: I60842285cd915d3c61b54003328408a8fc3d68f2
Related-Bug: #1620849
2016-09-09 10:45:41 +01:00
Jesse Pretorius
bf15d504ef Rename package lists (and related vars) appropriately
In order to make it easier to differentiate between the lists of
python packages, distribution packages, downloaded packages,
package pins and other similar variables the variable names are
being changed to ensure that they have a more explicit suffix
that defines the purpose and makes the naming more consistent.

This is to facilitate a lookup plugin which will be able to look
up all the package lists and present them as a consolidated piece
of data which may be used for artifact preparation.

Change-Id: I85fe0d5f4235c5d71ff1e8fc4066a9d1e0932684
14.0.0.0b3
2016-08-30 19:58:46 +01:00
Kevin Carter
03e48682de Enable log collection after functional testing
This change enables log collection within the gate so that further analysis
on gate tasks can be performed post build. This is very useful when
debugging problems.

Change-Id: I8e95d9aa322ea1f1006dcbca169cc518c0e1361d
Signed-off-by: Kevin Carter <kevin.carter@rackspace.com>
2016-08-29 21:37:17 -05:00
Jenkins
d85a98f0df Merge "Remove rally_host_group variable" 2016-08-24 19:25:36 +00:00
Travis Truman
c0698d207b Remove rally_host_group variable
It was duplicating the meaning/purpose of the role
variable `rally_role_project_group`

Also ensure that additional tasks are limited to only
a single host in the host group.

Change-Id: I3d5cc822cc0d3c2b0b3ba7b05a9fe1b6b9e3a839
2016-08-23 14:45:16 -04:00
Travis Truman
3d6a643eac [DOCS] - Use new documentation tree structure
Changes the rally role doc tree to the new structure
we are adopting for each role.

Change-Id: I8776c6953b65753d9bf54b13f3f7a282f3ce8df0
2016-08-22 16:07:06 -05:00
Jenkins
0c26304c64 Merge "Cleanup/standardize usage of tags" 2016-08-22 15:29:42 +00:00
Jesse Pretorius
50188e880d Make all linting tests use upper-constraints
As per [1] all linting tests can now use upper-constraints. This patch
removes all instances of the install_command override relating to lint
testing which were needed to negate the use of upper-constraints.

[1] http://lists.openstack.org/pipermail/openstack-dev/2016-August/101474.html

Change-Id: Ib3576a0333dee510d3f08aca6f4a9bbb1eeda4e5
2016-08-20 16:06:36 +01:00
Travis Truman
7b26715562 Cleanup/standardize usage of tags
The numerous tags within the role have been condensed
to two tags: rally-install and rally-config

These tags have been chosen as they are namespaced
and cover the two major functions of the role.

Change-Id: I781eb1edc8ea1d8bb093a579b9bb88498ed2d534
2016-08-20 09:35:17 -04:00
Jenkins
58ababd57d Merge "Functional testing for os_rally role" 2016-08-20 13:23:48 +00:00
Jenkins
64eb42d6bb Merge "Add SNI support via OS packages for os_rally" 2016-08-19 20:13:28 +00:00
Travis Truman
75bff29613 Make os_rally inventory group configurable
The default value of "rally_all" remains, but this
allows deployers to target the role to multiple
groups now.

Change-Id: Id1bbda227032f66270fe5656250be7794a1dd4af
2016-08-18 18:21:38 -04:00
Qin Wang
8ae853d309 Add SNI support via OS packages for os_rally
Some Linux distributions, such as CentOS 7 and Xenial, have trouble
validating SSL certificates when using get_url with servers
that use Server Name Indication (SNI).

This patch adds those packages to the list of required packages and
uses bindep to install them in developer test environments the same
way that the gate tests install them.

Change-Id: Ic3bf4b4238c1c6260d3c8dc0e4800ff26691ae93
2016-08-18 18:47:18 +00:00
Travis Truman
da91e5b015 Functional testing for os_rally role
The role gate will now actually run simple
Rally scenario against Keystone to validate that
the install and configuration is correct.

Change-Id: Ie5d52636700e8c276b0e793e815ae513d25415bb
2016-08-18 11:21:32 -04:00
OpenStack Proposal Bot
a11e603896 Updated from global requirements
Change-Id: I1388c5928f593025023ae831772c0e23dea1211b
2016-08-18 05:31:03 +00:00
Jesse Pretorius
6cca392b2a Add python packages for SNI support in tests
This adds python packages required for SNI support to ensure that tox
installs the packages into the venv when running tests.

Change-Id: I320e63df935ffa9ad0b561f16d7e42c2f03c7aac
2016-08-16 13:35:32 +00:00
Andreas Jaeger
292d0b0155 Move other-requirements.txt to bindep.txt
The default filename for documenting binary dependencies has been
changed from "other-requirements.txt" to "bindep.txt" with the release
of bindep 2.1.0. While the previous name is still supported, it will
be deprecated.

Move the file around to follow this change.

Note that this change is self-testing, the OpenStack CI infrastructure
will use a "bindep.txt" file to setup nodes for testing.

For more information about bindep, see also:
http://docs.openstack.org/infra/manual/drivers.html#package-requirements
http://docs.openstack.org/infra/bindep/

As well as this announcement:
http://lists.openstack.org/pipermail/openstack-dev/2016-August/101590.html

Change-Id: Ice1ab5f159882e55bc1550cb1ccd27bf07058c98
2016-08-12 21:01:23 +02:00
Jean-Philippe Evrard
a431c39a67 Include ansible commands for ansible linting
The plugin repo needs to be cloned for ansible-lint to
understand ansible plugins. The commands currently
reside in tox.ini under the ansible section and are not
currently included. This commit fixes that error.

Change-Id: I7d209c68ec1bf6760f84048d1f9983476ff82e68
2016-08-11 18:10:06 +01:00
Kevin Carter
449becae64 Disable stderr logging
OSLO logging currently defaults the 'use_stderr' option to True
which results duplicate logs in service daemon logs for both
upstart and systemd. To correct this issue the use_stderr
option has been set to false.

Change-Id: I3799265a48c8f92f9cef77a10b3f02fa6aa66b7f
Closes-Bug: 1588051
Signed-off-by: Kevin Carter <kevin.carter@rackspace.com>
2016-08-04 17:45:04 +00:00
Jesse Pretorius
087acfb6e8 Add project group to role
This patch adds a var used by the repo_build process to determine
which host group to check for members of before building the pip
packages required by this role. This provides the ability to
optimise the repo build process to only building the packages
that are required for an environment.

Depends-On: Idda16b4f382eee57c7469af898859d6d81d4eb30
Change-Id: Iedb4c0c91daa291f881a9fc00c5b8c40bb312ce3
2016-08-04 05:18:13 +01:00
Jesse Pretorius
61b08b72b1 Add ability to change apt/yum package state
The current method of installing the distribution packages required is
set in the tasks and cannot be changed by a deployer.

Currently the apt task always installs the latest package. This results
in unexpected binary changes when a deployer may simply be trying to
execute a configuration change.

This patch adds the ability for a deployer to change the desired state
so that the results are predictable.

Change-Id: I1708ca8285ffa2bbd1a989b187ef3c6d9dd005c2
2016-08-02 15:03:37 +01:00
Jenkins
600e2be755 Merge "Implement Ubuntu 16.04 support" 2016-07-29 10:48:10 +00:00
Jesse Pretorius
254418abe8 Ensure that doc linting is included in the linters test
The 'docs' tox target executes the doc8 lint test which may result in
failures when testing documentation builds, but OpenStack-CI does not
execute that tox target.

In order to ensure that we catch all standard documentation syntax
errors and prevent them from merging, this patch includes the docs
target in the 'linters' chain of tests.

Fixes for any failures which result from executing this test are also
included in the patch.

Change-Id: Iacff67847b0708a5d41ab3e1accf59f40326497d
2016-07-26 07:38:59 +01:00
Travis Truman
a998779940 Implement Ubuntu 16.04 support
Just noting in the role metadata that the role supports Xenial

Change-Id: I70fba8cd35f13405a0261d3aafab4681f2ca3ebf
Implements: blueprint support-ubuntu-1604
2016-07-21 13:27:11 -04:00
Jimmy McCrory
f7968fee28 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: Id9395e745249c723c5d8135ae4c9661dcb0f7221
2016-07-20 18:47:02 -07:00
Jesse Pretorius
8b068b08fe Optimise pip install tasks
Unlike the Ansible apt module, the Ansible pip module does not
recognise a with_items list and process all the items at once.

To optimise the pip install tasks, this patch replaces the use
of with_items with a join filter so that the pip install task
does an install with all the packages in a list, ensuring that
the execution is one action instead of many.

Change-Id: I403e36a67d2e06f5cd32fe28222b597a17ef42a1
2016-07-18 16:23:59 +01:00
Jesse Pretorius
32e3b2ad1f Use plugins repo version of the human_log callback plugin
With the implementation of https://review.openstack.org/321331 the
human_log callback plugin is now part of the plugins repo.

This patch removes the retrofitted version in tox in favor of using
the version from the plugins repo instead.

Change-Id: I173f065f004d3336f6249625c8c36a609742389e
2016-07-15 14:03:33 +01:00
Jenkins
857f19cf36 Merge "Updated from global requirements" 2016-07-15 10:30:38 +00:00
OpenStack Proposal Bot
3aca1307d4 Updated from global requirements
Change-Id: Ie80e071fd0600155086b4bafaa0f65a8ef27569c
2016-07-15 03:58:04 +00:00
Mike Carden
338cf7caf5 Remove duplicates from .gitignore
This patch removes the duplicated releasenotes/build
lines from .gitignore.

Change-Id: Ia69411f2a4fc7440c05a06efa96bd8b45fac4dbd
2016-07-15 12:07:22 +10:00
Jesse Pretorius
63c914f297 Implement doc8 checks for docs
In order to prepare for the move of detailed configuration
content from the install guide to the roles, doc8 checks
are being implemented in the roles to ensure that any new
content submitted is properly checked.

Change-Id: I4da740890257f083b4ba12ff4ed321933109d01b
Partially-Implements: blueprint osa-install-guide-overhaul
2016-07-13 12:56:47 +01:00
Jesse Pretorius
e46ba1c3a3 Update sphinx configuration
This patch updates the sphinx configuration for docs and releasenotes
to make it easier to replicate across repositories and to comply with
pep8 testing without exceptions.

Change-Id: I3a80b33771e4142dae589b7f6fbf0f94255cabc8
2016-07-12 16:53:56 +01:00
Jenkins
639114b31a Merge "Only install to virtual environment" 2016-07-08 21:00:42 +00:00
Jesse Pretorius
dc84bd9ae5 Update tox configuration
In order to prepare for implementing requirements management by the
OpenStack requirements management process, and to improve the
reliability and effectiveness of test execution, this patch implements
some changes to the tox configuration:

- The minimum tox version is increased in order to be able to use
  constraints for the python packages.
- The OpenStack upper-constraints are used when preparing the test
  venv for the linters checks.
- Any proxy environment variables set on the test host are passed
  into the venv to enable testing from behind a proxy.
- The environment variables used by Ansible tests are moved into
  a new venv called 'ansible' and this environment is inherited
  by all Ansible-related tests.
- The docs test will clean-up an existing build directory before
  executing the docs build.
- The releasenotes build cannot use upper-constraints at this point,
  so it doesn't.
- The Ansible role download will no longer ignore errors so that any
  problems discovered will result in a failed test.
- The human readable logging callback plugin is implemented for
  functional testing.
- The ansible test requirements are moved into tox.ini to ensure
  compliance for requirements.txt/test-requirements.txt for the
  global-requirements management contract.
- The ~/.ansible directory as a whole is not deleted. Instead only
  the plugins and roles folders are deleted to ensure that zuul's
  Ansible artifacts are left in-place.
- The ansible-lint version is updated to support execution against a
  folder, and the test now executes against the entire role to ensure
  that it captures all applicable files for lint testing.

This is a combined port of the following:
- https://review.openstack.org/323507
- https://review.openstack.org/338193
- https://review.openstack.org/332443
- https://review.openstack.org/338193
- https://review.openstack.org/339493

Change-Id: I03a60477abffb2b1c4a2dc7bd2979a22483a25a7
2016-07-08 13:36:18 +01:00
Anton Khaldin
1e1c8b35b9 Only install to virtual environment
Remove all tasks and variables related to toggling between installation
of rally 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: I815dff623fce1440a5d60f64bf69f4f563371998
Implements: blueprint only-install-venvs
2016-07-08 04:55:14 -07:00
Jimmy McCrory
717c085f63 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: Idf70fd3e14254ae7b633ca2731388dec307597da
2016-06-20 12:26:09 -07:00
Jenkins
a3d1f4908a Merge "Clean up container cache prep in tests" 2016-06-20 00:23:12 +00:00
Jesse Pretorius
b2587e2a38 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: Idc20aa8c21816d4d53ac374e0f99553cd8a5d0b2
2016-06-17 19:33:46 +01:00
Jesse Pretorius
3e9d62dede Pin test-requirements to match OpenStack requirements
A new release of flake8 is causing lint faiures. Our requirements
should match OpenStack requirements anyway.

This patch pins to the current master requirements from the
OpenStack requirements repository using global-requirements.

Change-Id: I722af00a4a530987a85c44fc5ae143b009eeb3ee
2016-06-17 12:35:50 +01:00
Jesse Pretorius
363ba685e2 Pin test-requirements to match OpenStack requirements
A new release of flake8 is causing lint faiures. Stable branches
should have requirements pinned anyway.

This patch pins to the current stable/mitaka requirements from
the OpenStack requirements repository.

Change-Id: Iefeb5e7e9b0f29fdcc8267e4d2a52a96ccf31fda
2016-06-16 16:17:44 +01:00
Jenkins
25114ed587 Merge "Updating os_rally to use the Multi-Distro framework" 2016-05-31 19:09:26 +00:00
Travis Truman
6f9765682a Updating os_rally to use the Multi-Distro framework
Debian-specific vars and logic have been moved to tasks
that will execute only on those distributions.

Change-Id: I6a9d04382b1f1badebf12483ce7d1d02b43f8903
Implements: blueprint multi-platform-host
2016-05-27 10:04:51 -04:00
Travis Truman
4fcb1576bb Verbose option has been deprecated from oslo.log
See http://lists.openstack.org/pipermail/openstack-dev/2016-May/095166.html
for additional details.

Change-Id: I47a9e18e209c676034809d9e0591a1eff6fb6883
2016-05-17 11:25:56 -04:00
Jenkins
ca93b07039 Merge "Remove py_from_git role" 2016-05-04 20:49:47 +00:00
Jenkins
c3a1bb2b67 Merge "Add .swp files to .gitignore" 2016-05-04 17:36:17 +00:00
Jesse Pretorius
05f9a7752f Add .swp files to .gitignore
Change-Id: Idf4fbd3a331ee5eafb78804dcfa6a90bbb515f1e
2016-05-04 15:21:15 +01:00
Jesse Pretorius
3c31f0c880 Change pip install task state to 'latest'
Currently all pip install tasks only require the package to be
present. This means that when an environment undergoes a minor
upgrade the package is not upgraded to the same version that
was tested with. This ultimately results in a deployed
environment that does not match the tested environment.

While for the services installed into venvs this is not an
issue, it does affect those which do not use venvs and any
packages which are installed outside of a venv or on top
of a venv.

This patch changes the behaviour to ensure that the install
task will always use the latest available package. In
developer_mode this will mean using the version specified
in upper-constraints, and in an integrated build this will
mean the version which is available in the wheel repo's
folder for the tag.

Change-Id: I04455f7323e6c565e46203494876e1812c5d0c1e
2016-05-04 10:42:30 +01:00
Jesse Pretorius
4b125868a9 Remove py_from_git role
The py_from_git role is removed as it is no longer required.

Change-Id: I193a3a19580a462a7561efb813be0f6480260374
2016-05-04 09:19:00 +01:00
Jesse Pretorius
114da46a39 Add dependencies for paramiko 2.0
Paramiko version 2.0 has been released. It now uses the Python library
cryptography. Installing this requires additional system packages. This
commit adds in the appropriate packages required by cryptography based
on its documentation [1].

An alternative approach would have been to constrain the version of
Paramiko however the project describes the 1.x versions as relying on
insecure dependencies [2].

[1] https://cryptography.io/en/latest/installation/
[2] http://www.paramiko.org/installing.html

Change-Id: I9ea9f7cbe946c9141189c4bcb9ba98656c8495b4
2016-05-03 08:56:52 +01:00