--- - name: Ensure PostgreSQL packages are installed. package: name: "{{ item }}" state: present enablerepo: "{{ postgresql_enablerepo }}" with_items: "{{ postgresql_packages }}" - name: Ensure PostgreSQL Python libraries are installed. package: name: "{{ postgresql_python_library }}" state: present enablerepo: "{{ postgresql_enablerepo }}"