https://github.com/croesnick/ansible-discover
Command line tool to list dependencies and dependants of Ansible roles and playbooks, respectively
https://github.com/croesnick/ansible-discover
ansible automation ci-tools
Last synced: about 1 year ago
JSON representation
Command line tool to list dependencies and dependants of Ansible roles and playbooks, respectively
- Host: GitHub
- URL: https://github.com/croesnick/ansible-discover
- Owner: croesnick
- License: mit
- Created: 2018-03-05T20:36:23.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2018-09-14T12:33:00.000Z (almost 8 years ago)
- Last Synced: 2024-12-17T10:07:00.011Z (over 1 year ago)
- Topics: ansible, automation, ci-tools
- Language: Python
- Size: 69.3 KB
- Stars: 4
- Watchers: 1
- Forks: 1
- Open Issues: 7
-
Metadata Files:
- Readme: README.rst
- Changelog: CHANGELOG.md
- License: LICENSE.txt
Awesome Lists containing this project
README
|Build Status| |PyPi Package|
ansible-discover
================
*ansible-discover* is a command line tool to list dependencies and
dependants of `Ansible` roles and playbooks, respectively.
One of its prime uses is in a CI tool like Jenkins. Once a change on,
say a role, is committed, use *ansible-discover* to gather the dependant
roles and playbooks. From this list, the respective CI jobs for playbook
and role validations may then be triggered.
Installation
------------
::
pip install ansible-discover
Usage
-----
One use case (like outlined above) is to determine all roles (directly
or indirectly) depending on a given set of roles:
::
ansible-discover roles predecessors PATHS
where ``PATHS`` is a space-delimited list of paths to roles (e.g.,
``roles/my_sample_role``).
In addition to predecessors (i.e., dependants) for roles, you can also
discover
- successors (i.e., dependencies) of roles:
``ansible-discover roles successors``;
- predecessors for playbooks:
``ansible-discover playbooks predecessors``; and
- successors of playbooks: ``ansible-discover playbooks successors``.
Related tools
-------------
- `ansigenome`_
- `ansible-roles-graph`_
- `ansible-review`_
License
-------
Distributed under the XYZ license. See ``LICENSE.txt`` for more
information.
Contributing
------------
- Fork it!
- Create your feature branch: ``git checkout -b my-new-feature``
- Commit your changes: ``git commit -am 'Add some feature'``
- Push to the branch: ``git push origin my-new-feature``
- Submit a pull request :)
.. _Ansible: https://github.com/ansible/ansible
.. _ansigenome: https://github.com/nickjj/ansigenome
.. _ansible-roles-graph: https://github.com/sebn/ansible-roles-graph
.. _ansible-review: https://github.com/willthames/ansible-review
.. |Build Status| image:: https://travis-ci.org/croesnick/ansible-discover.svg?branch=master
:target: https://travis-ci.org/croesnick/ansible-discover
.. |PyPi Package| image:: https://badge.fury.io/py/ansible-discover.svg
:target: https://badge.fury.io/py/ansible-discover