Greetings,
I currently register some variables via:
cat roles/configure_account_environment/tasks/main.yaml
---
# This playbook contains plays that will be run to configure an account.
-
name: get {{ primary_user }} account's home directory
shell: getent passwd {{ primary_user }} | cut -d ":" -f 6
register: home_directory
...and when I run the playbook I get:
[...]
TASK [configure_account_environment : get root account's home directory]
*********************
changed: [zed]
PLAY RECAP
***********************************************************************************
zed : ok=23 changed=2 unreachable=0 failed=0
skipped=1 rescued=0 ignored=0
[...]
Having variables that get registered show up as "changed" feels misleading
to me. Nothing is "changing" on the target node, I'm just getting some
information from that system.
Is there a way to mark registered variables as something other than
"changed" in the output of the playbook run?
Thanks for any hints and help!
-m
--
You received this message because you are subscribed to the Google Groups
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/ansible-project/CAOLfK3VTp8dU%3DzBhL%3Dy%3DSuF1ZcQ5wh3gVPEK3xNMc24yvG4kKg%40mail.gmail.com.