2017-09-13 19:57:24 -07:00
|
|
|
# ansible-galaxy
|
|
|
|
|
2017-09-13 20:01:49 -07:00
|
|
|
> Create and manage Ansible roles.
|
2019-06-03 02:06:36 +02:00
|
|
|
> More information: <https://docs.ansible.com/ansible/latest/cli/ansible-galaxy.html>.
|
2017-09-13 19:57:24 -07:00
|
|
|
|
2017-09-13 20:01:49 -07:00
|
|
|
- Install a role:
|
2017-09-13 19:57:24 -07:00
|
|
|
|
2021-07-08 12:27:17 +02:00
|
|
|
`ansible-galaxy install {{username}}.{{role_name}}`
|
2017-09-13 19:57:24 -07:00
|
|
|
|
2017-09-13 20:01:49 -07:00
|
|
|
- Remove a role:
|
2017-09-13 19:57:24 -07:00
|
|
|
|
2021-07-08 12:27:17 +02:00
|
|
|
`ansible-galaxy remove {{username}}.{{role_name}}`
|
2017-09-13 19:57:24 -07:00
|
|
|
|
2017-09-13 20:01:49 -07:00
|
|
|
- List installed roles:
|
2017-09-13 19:57:24 -07:00
|
|
|
|
|
|
|
`ansible-galaxy list`
|
|
|
|
|
2017-09-13 21:40:12 -07:00
|
|
|
- Search for a given role:
|
2017-09-13 19:57:24 -07:00
|
|
|
|
|
|
|
`ansible-galaxy search {{role_name}}`
|
|
|
|
|
2017-09-13 20:01:49 -07:00
|
|
|
- Create a new role:
|
2017-09-13 19:57:24 -07:00
|
|
|
|
2017-09-13 20:01:49 -07:00
|
|
|
`ansible-galaxy init {{role_name}}`
|
2021-07-08 12:27:17 +02:00
|
|
|
|
|
|
|
- Get information about a user role:
|
|
|
|
|
|
|
|
`ansible-galaxy role info {{username}}.{{role_name}}`
|
|
|
|
|
|
|
|
- Get information about a collection:
|
|
|
|
|
|
|
|
`ansible-galaxy collection info {{username}}.{{collection_name}}`
|