mirror of
https://github.com/ansible/awx.git
synced 2026-05-19 14:57:39 -02:30
add validation to InventorySource.inventory to avoid task manager death
see: https://github.com/ansible/awx/issues/1438
This commit is contained in:
@@ -1653,6 +1653,8 @@ class InventoryUpdate(UnifiedJob, InventorySourceOptions, JobNotificationMixin,
|
||||
organization_groups = []
|
||||
if self.inventory_source.inventory is not None:
|
||||
inventory_groups = [x for x in self.inventory_source.inventory.instance_groups.all()]
|
||||
else:
|
||||
inventory_groups = []
|
||||
selected_groups = inventory_groups + organization_groups
|
||||
if not selected_groups:
|
||||
return self.global_instance_groups
|
||||
|
||||
Reference in New Issue
Block a user