mirror of
https://github.com/netbox-community/netbox.git
synced 2024-05-10 07:54:54 +00:00
Only inventory active devices
This commit is contained in:
@ -37,7 +37,8 @@ class Command(BaseCommand):
|
|||||||
if options['password']:
|
if options['password']:
|
||||||
self.password = getpass("Password: ")
|
self.password = getpass("Password: ")
|
||||||
|
|
||||||
device_list = Device.objects.filter()
|
# Attempt to inventory only active devices
|
||||||
|
device_list = Device.objects.filter(status=True)
|
||||||
|
|
||||||
# --site: Include only devices belonging to specified site(s)
|
# --site: Include only devices belonging to specified site(s)
|
||||||
if options['site']:
|
if options['site']:
|
||||||
|
Reference in New Issue
Block a user