k8s: Fix .to_dict not needed (#56147)

* k8s: Fix .to_dict not needed

* Add changelog fragment
pull/57256/head
Fabrice 6 years ago committed by Will Thames
parent 7cd229aa97
commit 7364e79c0d

@ -0,0 +1,2 @@
bugfixes:
- k8s - resource updates applied with force work correctly now

@ -318,7 +318,7 @@ class KubernetesRawModule(KubernetesAnsibleModule):
result['result'] = k8s_obj result['result'] = k8s_obj
if wait: if wait:
success, result['result'], result['duration'] = self.wait(resource, definition, wait_timeout, condition=wait_condition) success, result['result'], result['duration'] = self.wait(resource, definition, wait_timeout, condition=wait_condition)
match, diffs = self.diff_objects(existing.to_dict(), result['result'].to_dict()) match, diffs = self.diff_objects(existing.to_dict(), result['result'])
result['changed'] = not match result['changed'] = not match
result['method'] = 'replace' result['method'] = 'replace'
result['diff'] = diffs result['diff'] = diffs

Loading…
Cancel
Save