From 47442b7c228716782a9115668b52b2a2686e0294 Mon Sep 17 00:00:00 2001 From: Fabio Alessandro Locati Date: Thu, 1 Dec 2016 14:03:39 +0000 Subject: [PATCH] Native YAML - databases/pgsql (#3606) --- .../database/postgresql/postgresql_lang.py | 24 +++++++++++++++---- 1 file changed, 20 insertions(+), 4 deletions(-) diff --git a/lib/ansible/modules/extras/database/postgresql/postgresql_lang.py b/lib/ansible/modules/extras/database/postgresql/postgresql_lang.py index f80d5b522b9..7e3b14279bc 100644 --- a/lib/ansible/modules/extras/database/postgresql/postgresql_lang.py +++ b/lib/ansible/modules/extras/database/postgresql/postgresql_lang.py @@ -119,16 +119,32 @@ EXAMPLES = ''' # Add language pltclu to database testdb if it doesn't exist and mark it as trusted: # Marks the language as trusted if it exists but isn't trusted yet # force_trust makes sure that the language will be marked as trusted -- postgresql_lang db=testdb lang=pltclu state=present trust=yes force_trust=yes +- postgresql_lang: + db: testdb + lang: pltclu + state: present + trust: yes + force_trust: yes # Remove language pltclu from database testdb: -- postgresql_lang: db=testdb lang=pltclu state=absent +- postgresql_lang: + db: testdb + lang: pltclu + state: absent # Remove language pltclu from database testdb and remove all dependencies: -- postgresql_lang: db=testdb lang=pltclu state=absent cascade=yes +- postgresql_lang: + db: testdb + lang: pltclu + state: absent + cascade: yes # Remove language c from database testdb but ignore errors if something prevents the removal: -- postgresql_lang: db=testdb lang=pltclu state=absent fail_on_drop=no +- postgresql_lang: + db: testdb + lang: pltclu + state: absent + fail_on_drop: no ''' try: