
Some Tips and Tricks for ansible
Created:
Updated:
129 words Β· 1 minute reading time
Table of contents
You will find here some all day work tips for ansible
loggingπ
log-path or notπ
I like to have several logs per ansible run. You can define a ANSIBLE_LOG_PATH in the Configuration file. Itβs static and when several users run several playbooks or Ad-Hoc Commands you will have mixed entries in the log.
one log per ansible runπ
The command below allows me to have one file per ansible run.
ANSIBLE_LOG_PATH=/tmp/ansible_log_$(date +%Y_%m_%d-%H_%M) \
ANSIBLE_DEBUG=True \
ansible-playbook -vvv your-playbook.ymlIn the ansible documentation are more information about Enabling Networking logging and how to read the logfile