Skip to content

Commit

Permalink
fix data types for output defaults
Browse files Browse the repository at this point in the history
  • Loading branch information
mikemorency committed Oct 1, 2024
1 parent 8ee0e3c commit f844603
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
4 changes: 4 additions & 0 deletions changelogs/fragments/103-improve-info-role.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
---
minor_changes:
- info - changed default filenames from randomly generated string to static filename to remove community dependency
- info - added optional output variable which includes gathered info
8 changes: 4 additions & 4 deletions roles/info/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,9 @@
- name: Expose Gathered Facts As Variable vmware_ops_info_outputs
ansible.builtin.set_fact:
vmware_ops_info_outputs:
license: "{{ __license.licenses | first | default({}) }}"
license: "{{ __license.licenses | default([]) }}"
appliance: "{{ __appliance.appliance | default({}) }}"
guest: "{{ __guests.guests | first | default({}) }}"
cluster: "{{ __clusters_info.results | map(attribute='clusters') | default({}) }}"
storage: "{{ __storage_policy.spbm_profiles | first | default({}) }}"
guest: "{{ __guests.guests | default([]) }}"
cluster: "{{ _clusters_info.results | default([]) | map(attribute='clusters') }}"
storage: "{{ __storage_policy.spbm_profiles | default([]) }}"
when: info_expose_outputs_as_variable

0 comments on commit f844603

Please sign in to comment.