From 55ab265986a7600b7fdfbcdf14298c9ce1104ccf Mon Sep 17 00:00:00 2001 From: Thanh Ha Date: Tue, 8 May 2018 12:36:26 -0400 Subject: [PATCH] Setup tools in global-jjb tox.ini Use -q to hide tox output. Creates a global tox.ini which can be used by projects to use common PyPi tools. This replaces the need to "source /path/to/venv" everywhere in our scripts to jump to different tools. Instead we replace it with one of: tox -q -c jjb/global-jjb/tox.ini -e openstack -- {parameters} tox -q -c jjb/global-jjb/tox.ini -e openstack {parameters} Non-CI management jobs can wget the tox.ini from global-jjb to pull the configuration. By default the version installed will be the latest patch version in semvar. The version comparison operator can be overrided via the *_VERSION_OP environment variable for each tool type. Install versions are also overridable via the *_VERSION environment variable. Ex: JJB_VERSION=2.0.6 JJB_VERSION_OP=">=" https://www.python.org/dev/peps/pep-0440/#version-specifiers Change-Id: I8b1a0936220ddbeb7f5e051ce15c421fec27c1a0 Signed-off-by: Thanh Ha --- tox.ini | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/tox.ini b/tox.ini index 25f28e86..2d4d91e6 100644 --- a/tox.ini +++ b/tox.ini @@ -40,3 +40,25 @@ commands = [testenv:license] deps = lftools commands = lftools license check-dir -r '.+' shell + +######### +# Tools # +######### + +[testenv:jenkins-jobs] +deps = + jenkins-job-builder{env:JJB_VERSION_OP:~=}{env:JJB_VERSION:2.0.9} +commands = + jenkins-jobs {posargs:--help} + +[testenv:lftools] +deps = lftools{env:LFTOOLS_VERSION_OP:~=}{env:LFTOOLS_VERSION:0.13.0} +commands = lftools {posargs:--help} + +[testenv:openstack] +deps = python-openstackclient{env:OPENSTACK_VERSION_OP:~=}{env:OPENSTACK_VERSION:3.15.0} +commands = openstack {posargs:--help} + +[testenv:reno] +deps = reno{env:RENO_VERSION_OP:~=}{env:RENO_VERSION:2.9.1} +commands = reno {posargs:--help} -- 2.16.6