How do i see stdout for ansible-playbook commands? -v only shows ansible output, not the individual commands. It would be great if i could figure out how to do this immediately so that if something fails or hangs i can see why

e.g.

- name: print to stdout
  action: command echo "hello"

would print

TASK: [print variable] ********************************************************

hello
Best Answer


I think you can register the result to a variable, then print with debug.

- name: print to stdout
  command: echo "hello"
  register: hello

- debug: msg=""

- debug: msg=""