Skip to content
Denis Gasparin edited this page Oct 1, 2017 · 2 revisions

Add the role rtshome.pgsql to your playbook (or your own role) as you would with any other role:

    - hosts: servers
      tasks:
      roles:
        - rtshome.pgsql

The role itself doesn't do anything but adding it to your playbook allows you to use the provided pgsql_* modules:

- hosts: servers
  tasks:
    - postgresql_query:
        database: acme
        query: SELECT * FROM config WHERE env = %(env)s
        parameters:
        env: production 
      register: query

  roles:
    - rtshome.pgsql
Clone this wiki locally