Fix ansible-lint job
The 'linters' tox environment was not running on roles, it was only
running on playbooks. This change adds a command to the linters
environment to ensure all roles are linted. This also cleans up a
comment in the tox file that was referring to a nonexistent zuul job.
@@ -15,7 +15,7 @@ setenv =
passenv =
# NOTE(pabelanger): if you'd like to run tox -elinters locally, you'll need
# to export ANSIBLE_ROLES_PATH pointing to the currect repos.
- # see infra-zuul-jobs-linters job for more information.
+ # see openstack-zuul-jobs-linters job for more information.
ANSIBLE_ROLES_PATH
# Add dependencies here since other jobs use python2 and zuul requires
# python3.
@@ -35,6 +35,8 @@ commands =
# [ANSIBLE0012] Commands should not change things if nothing needs doing
bash -c "find playbooks -type f -regex '.*.ya?ml' -print0 | \
xargs -t -n1 -0 ansible-lint -xANSIBLE0012"
+ bash -c 'find roles -maxdepth 1 -mindepth 1 -type d -printf "%p/\n" | \
+ xargs -t -n1 ansible-lint -xANSIBLE0012'
# Ansible Syntax Check
bash -c "find playbooks -type f -regex '.*.ya?ml' -exec \
ansible-playbook --syntax-check -i {toxinidir}/tests/inventory \
