�
�Udac @` s� d d l m Z m Z m Z e Z d Z d d l Z d d l Z d d l Z d d l
m Z d d l m
Z
d d l m Z d d l m Z d d l m Z d e f d
� � YZ d S( i ( t absolute_importt divisiont print_functions�
callback: log_plays
type: notification
short_description: write playbook output to log file
version_added: historical
description:
- This callback writes playbook output to a file per host in the `/var/log/ansible/hosts` directory
requirements:
- Whitelist in configuration
- A writeable /var/log/ansible/hosts directory by the user executing Ansible on the controller
options:
log_folder:
version_added: '2.9'
default: /var/log/ansible/hosts
description: The folder where log files will be created.
env:
- name: ANSIBLE_LOG_FOLDER
ini:
- section: callback_log_plays
key: log_folder
N( t
makedirs_safe( t to_bytes( t MutableMapping( t AnsibleJSONEncoder( t CallbackBaset CallbackModulec B` s� e Z d Z d Z d Z d Z e Z d Z d Z d � Z
d d d d � Z d � Z
e d � Z d
� Z d d � Z d � Z d
� Z d � Z d � Z RS( sD
logs playbook results, per host, in /var/log/ansible/hosts
g @t notificationt log_playss %b %d %Y %H:%M:%Ss# %(now)s - %(category)s - %(data)s
c C` s t t | � j � d S( N( t superR t __init__( t self( ( sF /usr/lib/python2.7/site-packages/ansible/plugins/callback/log_plays.pyR <