travis: add ansible-lint

This commit is contained in:
juju4 2019-11-09 20:23:17 -05:00
parent 880a80ca52
commit 2c44ca6b36

@ -54,8 +54,10 @@ script:
- 'sudo docker run --detach --volume="${PWD%/*}":/etc/ansible/roles:ro ${run_opts} ${distribution}-${version}:ansible "${init}" > "${container_id}"'
- 'sudo docker exec --tty "$(cat ${container_id})" env TERM=xterm ansible --version'
- 'sudo docker exec --tty "$(cat ${container_id})" env TERM=xterm pip install ansible-lint || true'
# Ansible syntax check.
- 'sudo docker exec --tty "$(cat ${container_id})" env TERM=xterm ansible-lint /etc/ansible/roles/juju4.fprobe/tasks/main.yml || true'
- 'sudo docker exec --tty "$(cat ${container_id})" env TERM=xterm ansible-playbook /etc/ansible/roles/juju4.fprobe/test/integration/default/default.yml --syntax-check'
# Test role.