diff --git a/core/services/cable_guy/main.py b/core/services/cable_guy/main.py index f85486b3e..1eeab453d 100755 --- a/core/services/cable_guy/main.py +++ b/core/services/cable_guy/main.py @@ -144,6 +144,14 @@ def update_host_dns(dns_data: DnsData) -> Any: manager.dns.update_host_nameservers(dns_data) +app = VersionedFastAPI( + app, + version="1.0.0", + prefix_format="/v{major}.{minor}", + enable_latest=True, +) + + @app.get("/") async def root() -> HTMLResponse: html_content = """ @@ -156,13 +164,6 @@ async def root() -> HTMLResponse: return HTMLResponse(content=html_content, status_code=200) -app = VersionedFastAPI( - app, - version="1.0.0", - prefix_format="/v{major}.{minor}", - enable_latest=True, -) - if __name__ == "__main__": if os.geteuid() != 0: logger.error(