mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-08 14:22:46 +00:00
icinga2_host: fix a key error when modifying an existing host (#6748)
* Initialize `template` variable. Add changelog fragment. * Update changelogs/fragments/6286-icinga2_host-template-and-template-vars.yml Co-authored-by: Felix Fontein <felix@fontein.de> * icinga2_host: fix a key error when updating a host * Changelog fragment. * Update changelog fragment with correct PR number. --------- Co-authored-by: Felix Fontein <felix@fontein.de>
This commit is contained in:
2
changelogs/fragments/6748-icinga2_host-datafix.yml
Normal file
2
changelogs/fragments/6748-icinga2_host-datafix.yml
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
bugfixes:
|
||||||
|
- "icinga2_host - fix a key error when updating an existing host (https://github.com/ansible-collections/community.general/pull/6748)."
|
||||||
@@ -306,7 +306,7 @@ def main():
|
|||||||
module.exit_json(changed=False, name=name, data=data)
|
module.exit_json(changed=False, name=name, data=data)
|
||||||
|
|
||||||
# Template attribute is not allowed in modification
|
# Template attribute is not allowed in modification
|
||||||
del data['attrs']['templates']
|
del data['templates']
|
||||||
|
|
||||||
ret = icinga.modify(name, data)
|
ret = icinga.modify(name, data)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user