Package: ansible-butler
ansible-butlerButler CLI for Ansible projectsFunctionsObjectActionDescriptiondirectoryinitinitialize an ansible directorydirectorycleancleanup an ansible directoryeeinitinitialize an execution environment directory for ansible-buildereedependencies[deps]parse the dependency tree based on execution environment definition (or collection requirements)rolelistlist rolesroledependencies[deps]Build a dependency graph between roles in a specified directoryrolecleanclean role directory structure (remove empty yml files & dirs)rolemk-readmeauto generate readme based on role meta and basic yml infoplaybookupdatemap legacy module names to FQCNsplaybooklist-collections[lc]list collections used in a playbook (following include_* directives)UsageUsage:
  ansible-butler directory init [<dir>] [--config=PATH]
  ansible-butler directory clean [<dir>] [--skip-roles]
  ansible-butler ee init [<dir>] [--config=PATH]
  ansible-butler ee [dependencies|deps] [--config=PATH] [<name>]
  ansible-butler role list [--roles-path=PATH] [<name> --recursive]
  ansible-butler role [dependencies|deps] [--roles-path=PATH]
  ansible-butler role clean [--roles-path=PATH] [<name> --recursive]
  ansible-butler role mk-readme [--roles-path=PATH] [<name> --recursive]
  ansible-butler playbook update [--context=CONTEXT] [--config=PATH] [<name>] [--recursive] [--force]
  ansible-butler playbook [list-collections|lc] [--context=CONTEXT] [--config=PATH] [<name>] [--recursive] [--force]

Arguments:
  name    name of target (accepts glob patterns)
  dir     path to directory [default: ./]

Options:
  -h --help           Show this screen
  -r --recursive      Apply glob recursively [default: False]
  -f --force          Make file changes in place
  --config=PATH       Path to config file
  --roles-path=PATH   Path to roles directory [default: ./roles]
  --context=CONTEXT   Path to context directory [default: ./]
  --skip-roles        Flag to skip cleaning rolesExamplesInitialize Ansible Directoryansible-butler directory init ./sandboxansible-butler directory init ./sandbox --config=~/configs/ansible-butler.ymlClean an Ansible Directoryansible-butler directory clean ./sandboxansible-butler directory clean ./sandbox --skip-rolesInitialize Execution Environment Directoryansible-butler ee init ./ee-windowsansible-butler ee init ./ee-windows --config=~/configs/ansible-butler.ymlInspect Execution Environment Dependenciesansible-butler ee dependencies execution-environment.ymlansible-butler ee deps requirements.yml --config=~/configs/ansible-butler.ymlClean Rolesansible-butler role clean my-role-1ansible-butler role clean my-role-*List Rolesansible-butler role listansible-butler role list ansible_collections/namespace/collection/rolesGenerate Dependency Graphansible-butler role depsansible-butler role deps ansible_collections/namespace/collection/rolesGenerate READMEansible-butler role mk-readme my-role-1ansible-butler role mk-readme my-role-*Update Playbooksansible-butler playbook update --context=./playbooks -ransible-butler playbook update legacy-*.ymlansible-butler playbook update -fList Collectionsansible-butler playbook list-collections --context=./playbooks -ransible-butler playbook lc example-playbook.ymlConfigurationCreate an.ansible-butler.ymlin one or more of the following locations:/etc/ansible-butler/    ## least precedence
~/
./                      ## highest precedenceYou can also specify a specific path at runtime via the--configoption.# Example Configuration Schemaexecution_environment:init:version:2ansible_config:ansible.cfgee_base_image:quay.io/ansible/ansible-runner:latestee_builder_image:quay.io/ansible/ansible-builder:latestprepend_build_steps:-...append_build_steps:-...directory:init:folders:-name:pluginsfolders:...files:-README.mdfiles:-playbook.ymlrole:dependencies:output_fmt:html# [html,json]output_dest:graph.htmlinclude_tests:falsemaster_node:role-common-setupinitial_direction:downstreamtitle:ansible-butler roles dependency graphtitle_text_color:whitetitle_background_color:blacktree_options:# Customize the color palettecircleStrokeColor:'#2b8f91'linkStrokeColor:'#dddddd'closedNodeCircleColor:'#9bd3d4'openNodeCircleColor:whitecyclicNodeColor:'#FF4242'missingNodeColor:'#CC0100'maxDepthNodeColor:'#FF5850'playbook:update:modules:smart_device:redirect:zjleblanc.kasa.smart_devicecustom_module:redirect:company.it.custom_module🔗 Default configuration file🔗 Example adding test plugins directory🔗 Example adding module redirectsTroubleshootingansible-butler: command not foundcheck the $PATH environment variable and ensure that~/.local/binis includedLicenseGNU General Public LicenseAuthor InformationZach LeBlancRed Hat