#Is there a way to print out a secret to stdout but not logging it to log file?

1 messages · Page 1 of 1 (latest)

wild field
#

I need a playbook to download secret (password as example) to show to service engineer, but I don't want it to be logged to log file (ansible.log for example). I tried no_log: true, but it does not print secret to stdout.

- name: print secret
  debug:
    msg: "secret is {{ secret }}"
  no_log: true

This task ends up print nothing.

hidden slate