mirror of
https://github.com/craigerl/aprsd.git
synced 2025-08-27 16:52:34 -04:00
fixed references to conf
This commit is contained in:
parent
a1e21e795d
commit
7a5b55fa77
@ -18,7 +18,7 @@ class APRSRegistryThread(aprsd_threads.APRSDThread):
|
|||||||
def __init__(self):
|
def __init__(self):
|
||||||
super().__init__("APRSRegistryThread")
|
super().__init__("APRSRegistryThread")
|
||||||
self._loop_cnt = 1
|
self._loop_cnt = 1
|
||||||
if not CONF.registry.enabled:
|
if not CONF.aprs_registry.enabled:
|
||||||
LOG.error(
|
LOG.error(
|
||||||
"APRS Registry is not enabled. ",
|
"APRS Registry is not enabled. ",
|
||||||
)
|
)
|
||||||
@ -29,17 +29,17 @@ class APRSRegistryThread(aprsd_threads.APRSDThread):
|
|||||||
|
|
||||||
def loop(self):
|
def loop(self):
|
||||||
# Only call the registry every N seconds
|
# Only call the registry every N seconds
|
||||||
if self._loop_cnt % CONF.registry.frequency_seconds == 0:
|
if self._loop_cnt % CONF.aprs_registry.frequency_seconds == 0:
|
||||||
info = {
|
info = {
|
||||||
"callsign": CONF.callsign,
|
"callsign": CONF.callsign,
|
||||||
"description": CONF.registry.description,
|
"description": CONF.aprs_registry.description,
|
||||||
"service_website": CONF.registry.service_website,
|
"service_website": CONF.aprs_registry.service_website,
|
||||||
"software": f"APRSD version {aprsd.__version__} "
|
"software": f"APRSD version {aprsd.__version__} "
|
||||||
"https://github.com/craigerl/aprsd",
|
"https://github.com/craigerl/aprsd",
|
||||||
}
|
}
|
||||||
try:
|
try:
|
||||||
requests.post(
|
requests.post(
|
||||||
f"{CONF.registry.registry_url}/api/v1/register",
|
f"{CONF.aprs_registry.registry_url}/api/v1/register",
|
||||||
json=info,
|
json=info,
|
||||||
)
|
)
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user