From 8a928ef70dacd8fb221e1379510d127fccde9bd0 Mon Sep 17 00:00:00 2001 From: Monty Taylor Date: Fri, 15 May 2020 07:39:29 -0500 Subject: [PATCH] Build collection with 2.10 and ignore things more better We need 2.10 for building collection tarballs with build_ignore. Also, build_ignore takes globs, not leading filepaths, so add globs to the dirs in our list so that we properly don't include these. Change-Id: I809e100fa80bffafda4002487590a6dcd6aea0c1 --- galaxy.yml.in | 8 ++++---- tox.ini | 7 +++++++ 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/galaxy.yml.in b/galaxy.yml.in index 45542d3e..fb0d692b 100644 --- a/galaxy.yml.in +++ b/galaxy.yml.in @@ -15,13 +15,13 @@ homepage: https://opendev.org issues: https://review.opendev.org/q/project:openstack/ansible-collections-openstack build_ignore: - "*.tar.gz" - - build_artifact/ - - ci/ + - build_artifact/* + - ci/* - galaxy.yml.in - setup.cfg - test-requirements.txt - - tests/ - - tools/ + - tests/* + - tools/* - tox.ini - .zuul.yaml - .pytest_cache diff --git a/tox.ini b/tox.ini index e48c58f9..bb21394d 100644 --- a/tox.ini +++ b/tox.ini @@ -27,7 +27,14 @@ commands = stestr run {posargs} commands = flake8 +# NOTE(mordred): Until ansible 2.10 is released we need to override deps for this env +# here because we need to use 2.10 galaxy to build the collection and properly +# respect build_ignore [testenv:build] +deps = + pbr + ruamel.yaml + git+https://github.com/ansible/ansible commands = python {toxinidir}/tools/build.py ansible-galaxy collection build --force {toxinidir} --output-path {toxinidir}/build_artifact