W3cubDocs

/Ansible 2.11

ansible.builtin.tree – Save host events to files

Note

This module is part of ansible-base and included in all Ansible installations. In most cases, you can use the short module name tree even without specifying the collections: keyword. Despite that, we recommend you use the FQCN for easy linking to the module documentation and to avoid conflicting with other collections that may have the same module name.

New in version 2.0: of ansible.builtin

Synopsis

  • This callback is used by the Ansible (adhoc) command line option -t|–tree
  • This produces a JSON dump of events in a directory, a file for each host, the directory used MUST be passed as a command line option.

Requirements

The below requirements are needed on the local controller node that executes this callback.

  • invoked in the command line

Parameters

Parameter Choices/Defaults Configuration Comments
directory
path
added in 2.11 of ansible.builtin
Default:
"~/.ansible/tree"
ini entries:

[callback_tree]
directory = ~/.ansible/tree

env:ANSIBLE_CALLBACK_TREE_DIR
directory that will contain the per host JSON files. Also set by the ``--tree`` option when using adhoc.

© 2012–2018 Michael DeHaan
© 2018–2021 Red Hat, Inc.
Licensed under the GNU General Public License version 3.
https://docs.ansible.com/ansible/2.11/collections/ansible/builtin/tree_callback.html