How to convert a dictionary of dictionaries into a list of dictionaries in a Ansible vars file?

前端 未结 1 536
没有蜡笔的小新
没有蜡笔的小新 2021-01-11 15:52

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.

Input:

         


        
1条回答
  •  再見小時候
    2021-01-11 15:58

    {{ postgres_users.values() | list }} seems to do it.

    0 讨论(0)
提交回复
热议问题