mirror of
https://github.com/lopes/netbox-scanner.git
synced 2025-07-24 14:24:56 +02:00
add dns name
This commit is contained in:
parent
8dc40a7534
commit
79f06166da
@ -62,9 +62,12 @@ class NetBoxScanner(object):
|
|||||||
logging.info(f'unchanged: {host[0]}/32 "{host[1]}"')
|
logging.info(f'unchanged: {host[0]}/32 "{host[1]}"')
|
||||||
self.stats['unchanged'] += 1
|
self.stats['unchanged'] += 1
|
||||||
else:
|
else:
|
||||||
|
print(host)
|
||||||
|
print(self.tag)
|
||||||
self.netbox.ipam.ip_addresses.create(
|
self.netbox.ipam.ip_addresses.create(
|
||||||
address=host[0],
|
address=host[0],
|
||||||
tags=[self.tag],
|
tags=[self.tag],
|
||||||
|
dns_name=host[1],
|
||||||
description=host[1]
|
description=host[1]
|
||||||
)
|
)
|
||||||
logging.info(f'created: {host[0]}/32 "{host[1]}"')
|
logging.info(f'created: {host[0]}/32 "{host[1]}"')
|
||||||
|
Loading…
x
Reference in New Issue
Block a user