ansible/ansible — pull request #2676 by b6d (2013-04-13 21:24:07+00:00)
Title: Proposal for a module to manage PostgreSQL privileges (2)

As suggested there, here is is a squashed commit of pull request #2536 (with some refinements made in the meantime) for review.

Examples can be found in the EXAMPLES-docstring.

Commit Message:

This Module allows to manage privileges on PostgreSQL database objects
(currently: tables, sequences, functions, databases, schemas, languages and
tablespaces) as well as group role memberships.

It is basically a wrapper around most of the functionality of PostgreSQL's
GRANT and REVOKE statements with additional detection of changes and support
for dry-runs (check-mode).

postgresql_privs should work with PostgreSQL 8.4 and above. Python Module
psycopg2 is required on the remote host.