From ef54e0410cd547f0d5d6ed1a6621f7dcfc7c709e Mon Sep 17 00:00:00 2001 From: Zim Kalinowski Date: Mon, 18 Feb 2019 14:04:01 +0800 Subject: [PATCH] fixed merge conflicts --- .../fragments/52388-postgresqldatabase-fix-force-update.yml | 2 ++ lib/ansible/modules/cloud/azure/azure_rm_postgresqldatabase.py | 2 ++ 2 files changed, 4 insertions(+) create mode 100644 changelogs/fragments/52388-postgresqldatabase-fix-force-update.yml diff --git a/changelogs/fragments/52388-postgresqldatabase-fix-force-update.yml b/changelogs/fragments/52388-postgresqldatabase-fix-force-update.yml new file mode 100644 index 00000000000..50e82408dfe --- /dev/null +++ b/changelogs/fragments/52388-postgresqldatabase-fix-force-update.yml @@ -0,0 +1,2 @@ +bugfixes: + - azure_rm_postgresqldatabase - fix force_update bug (https://github.com/ansible/ansible/issues/50978). diff --git a/lib/ansible/modules/cloud/azure/azure_rm_postgresqldatabase.py b/lib/ansible/modules/cloud/azure/azure_rm_postgresqldatabase.py index 305a8fb7235..f758e99b7e4 100644 --- a/lib/ansible/modules/cloud/azure/azure_rm_postgresqldatabase.py +++ b/lib/ansible/modules/cloud/azure/azure_rm_postgresqldatabase.py @@ -146,6 +146,7 @@ class AzureRMDatabases(AzureRMModuleBase): self.resource_group = None self.server_name = None self.name = None + self.force_update = None self.parameters = dict() self.results = dict(changed=False) @@ -200,6 +201,7 @@ class AzureRMDatabases(AzureRMModuleBase): if not self.check_mode: self.delete_postgresqldatabase() else: + self.fail("Database properties cannot be updated without setting 'force_update' option") self.to_do = Actions.NoAction if (self.to_do == Actions.Create) or (self.to_do == Actions.Update):