This commit is contained in:
Alex_geth
2022-05-27 17:45:12 +03:00
parent f6b0da976b
commit e058925f9b
2 changed files with 3 additions and 0 deletions

View File

@@ -333,6 +333,8 @@ def main():
if subj.k8s_should_exist:
subj.result['facts'] = subj.package_facts(amodule.check_mode)
amodule.exit_json(**subj.result)
else:
amodule.exit_json(**subj.result)
if __name__ == "__main__":
main()

View File

@@ -2857,6 +2857,7 @@ class DecortController(object):
self.decort_api_call(requests.post, "/restmachine/cloudapi/k8s/delete", api_params)
# On success the above call will return here. On error it will abort execution by calling fail_json.
self.result['failed'] = False
self.result['msg'] = "k8s_delete() K8s cluster ID {} was deleted.".format(k8s_id)
self.result['changed'] = True
return