{"action":"opened","issue":{"url":"https://api.github.com/repos/Icinga/icinga2/issues/5722","repository_url":"https://api.github.com/repos/Icinga/icinga2","labels_url":"https://api.github.com/repos/Icinga/icinga2/issues/5722/labels{/name}","comments_url":"https://api.github.com/repos/Icinga/icinga2/issues/5722/comments","events_url":"https://api.github.com/repos/Icinga/icinga2/issues/5722/events","html_url":"https://github.com/Icinga/icinga2/issues/5722","id":271748504,"number":5722,"title":"using icinga director, remove hosts (with empty zone as result) doesn't work","user":{"login":"tlo8640","id":740897,"avatar_url":"https://avatars1.githubusercontent.com/u/740897?v=4","gravatar_id":"","url":"https://api.github.com/users/tlo8640","html_url":"https://github.com/tlo8640","followers_url":"https://api.github.com/users/tlo8640/followers","following_url":"https://api.github.com/users/tlo8640/following{/other_user}","gists_url":"https://api.github.com/users/tlo8640/gists{/gist_id}","starred_url":"https://api.github.com/users/tlo8640/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tlo8640/subscriptions","organizations_url":"https://api.github.com/users/tlo8640/orgs","repos_url":"https://api.github.com/users/tlo8640/repos","events_url":"https://api.github.com/users/tlo8640/events{/privacy}","received_events_url":"https://api.github.com/users/tlo8640/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2017-11-07T08:36:56Z","updated_at":"2017-11-07T08:36:56Z","closed_at":null,"author_association":"NONE","body":"Hello\r\ncoming from\r\n\r\nIcinga/icingaweb2-module-director#1219\r\n\r\nDon't know if this is a Icingaweb2 Director Problem or an Icinga2 Problem.\r\nTried it on different icinga2 setupups and ran always into this problem.\r\n\r\nUsing Icinga Director for configuring icinga2. When you try to remove hosts, wich would lead into an empty zone. The hosts will be removed from Director, but they still exist in icinga2 config after deploying the director config.\r\nExpected Behavior\r\n\r\nHost should be removed from Icinga2 config, too.\r\n\r\nCurrent Behavior\r\n\r\nWhen you are using Icinga Director for configuring Icinga2 and you want to remove some hosts and after removing a zone would be empty, these hosst aren't removed from icinga2, but they are removed from Icinga2 Director.\r\nPossible Solution\r\n\r\nDon't know how Icinga Director deploys its config. When deploying the new config with the empty zone, no hostz config for the empty zone is created (seem to me) and therefore this zone will not be touched and keeps it former config?\r\nSteps to Reproduce (for bugs)\r\n\r\n1.setup icinga2 with director\r\n2.create one or more zones\r\n3. deploy one or more hosts into the zone(s), only hostchecks are ok\r\n4. remove all hosts from one zone so that the zone should be empty\r\n5. deploy new config with director\r\n6. voila: the removed hosts still exist in icinga2, but are removed from director\r\n\r\nContext\r\n\r\nFirst we ran into this problem when we tried configuration with Icinga Director, because not so many Hosts where in the testing environment and they were often added and removed.\r\nAlso in production the problem could be a problem, for instance, when you redesign your zones infrastructure or something like this and you have to move servers between zones.\r\nYour Environment\r\n\r\n    Director version (System - About): 1.4.1\r\n    Version used (icinga2 --version): 2.7.1.1\r\n    Operating System and version: RHEL 7.4\r\n"}}
{"actor":{"display_login":"tlo8640"}}