ansible-playbook and different screen / file log output

Hello,

I was wondering if such a logging scenario is possible out of the box with Ansible or it it something which would need to be implemented as a custom callback plugin:

  • on screen (stdout), I’d like to see all changed/failed/warning tasks but not the ok/skipped tasks
  • if it was just this, I’d use parameters from https://docs.ansible.com/ansible/latest/plugins/callback/default.html, namely env:ANSIBLE_DISPLAY_OK_HOSTS and env:ANSIBLE_DISPLAY_SKIPPED_HOSTS- in a log file (ideally in structure such as by tree plugin but even a single output file ANSIBLE_LOG_PATH would be ok) I’d like to log all the tasks, no matter their status
    I was trying several combinations of settings but wasn’t lucky; whenever the console output was shortened, so was the information in the log file.

Any suggestions?

Thanks,
Waldek