How to convert a dictionary of dictionaries into a list of dictionaries in a Ansible vars file?
<p>Within an Ansible vars file, I want to convert a dict of dicts into a list of dicts that I can pass to an external role from Ansible Galaxy. </p>

<p>Input:</p>

<pre><code>postgres_users:
  dc1:
    name: user_dc1
    password: pass_dc1
  dc2:
    name: user_dc2
    password: pass_dc2
  dc3:
    name: user_dc3
    password: pass_dc3
</code></pre>

<p>Desired output:</p>

<pre><code>postgres_users:
  - name: user_dc1
    password: pass_dc1
  - name: user_dc2
    password: pass_dc2
  - name: user_dc3
    password: pass_dc3
</code></pre>

<p>Is there a simple way to do this within an Ansible vars file?</p>