Hello,

I run a command via looping in a "with_items" and registering the output 
into a hash with the item as a key.

However when I do this, I am having difficulty referencing the specific 
results when I try and key on "item" later.

I want to know which SID is unavailable (I only care if it tnspings, I will 
check actually logging in later).

Assume this_database_sid_list is an array of ['db1','db2','db3']

Playbook snippet:

- name: Ensure all SIDS this app needs are available on each server
  command: "tnsping {{ item }}"
  with_items: "{{ this_database_sid_list }}"
  register: tnsping_results <--- can I register with a key of item???

- name: See results
  debug: msg="Result is {{ tnsping_results.item.stdout }}" <--- ???? how do 
I reference the results with the key of item?
  with_items: "{{ this_database_sid_list }}"

-- 
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 post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/1d01765e-e79f-4f5b-92ac-eb48b403e67b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to