glpi-project / glpi-inventory-plugin

GLPI Inventory plugin
GNU Affero General Public License v3.0
46 stars 27 forks source link

Unmanaged Devices always created in Root Entity #552

Closed fabriceverkor closed 1 month ago

fabriceverkor commented 2 months ago

Describe the bug

Discovery task and IP range are in 'Facility' Unmanaged Devices are always created in Root Entity, not in 'Facility'

To reproduce

1- create an IP range in 'Facility' entity 2- create a NetDiscovery task in 'Facility' entity and associated to IP range above 3- run the task

Expected behavior

Unmanaged Devices should be created in 'Facility' entity, not in Root entity.

Operating system

Linux

GLPI Agent version

1.5

GLPI version

10.0.10

GLPIInventory plugin

1.3.4

Additional context

No response

trasher commented 1 month ago

Does not seems a bug; I do not think it has ever worked like this.

stonebuzz commented 1 month ago

After rereading the code, the management of unmanaged elements is based on this option for the destination entity

image

Unmanaged then passes to the rules for assigning an element to an entity

image

trasher commented 1 month ago

Using entities rules is certainly the way to go there.

Using IP range entity would be a new feature, if it would be accepted. I close this one.