diff --git a/nbs/__init__.py b/nbs/__init__.py index ee79cc3..764a261 100644 --- a/nbs/__init__.py +++ b/nbs/__init__.py @@ -41,8 +41,9 @@ def sync_host(self, host): ''' try: nbhost = self.netbox.ipam.ip_addresses.get(address=host[0]) - except ValueError: - logging.error(f'duplicated: {host[0]}/32') + except ValueError as e: + logging.error(e) + logging.error(f'possibly duplicated: {host[0]}/32') self.stats['errors'] += 1 return False diff --git a/netbox-scanner.conf b/netbox-scanner.conf index e36825f..3988316 100644 --- a/netbox-scanner.conf +++ b/netbox-scanner.conf @@ -1,4 +1,5 @@ [NETBOX] +# format => http(s)://IP:PORT address = token = logs = logs/ diff --git a/requirements.txt b/requirements.txt index 0bc0275..ed9fef9 100644 --- a/requirements.txt +++ b/requirements.txt @@ -2,6 +2,7 @@ certifi==2020.4.5.1 chardet==3.0.4 idna==2.9 pynetbox==4.3.1 -requests==2.23.0 -six==1.15.0 -urllib3==1.26.5 +requests +six +urllib3 +setuptools \ No newline at end of file