mirror of
https://github.com/hyperknot/openfreemap.git
synced 2026-05-22 14:32:15 +00:00
work
This commit is contained in:
14
http-host.py
14
http-host.py
@@ -88,16 +88,20 @@ def debug():
|
|||||||
ip=server['ip'],
|
ip=server['ip'],
|
||||||
version=version,
|
version=version,
|
||||||
)
|
)
|
||||||
print(f' {domain} OK')
|
print(f' {domain} {click.style("OK", fg="green")}')
|
||||||
except AssertionError:
|
except AssertionError:
|
||||||
print(f' {domain} FAILED - Version mismatch (expected {version})')
|
print(
|
||||||
|
f' {domain} {click.style("FAILED", fg="red")} - Version mismatch (expected {version})'
|
||||||
|
)
|
||||||
server_ok = False
|
server_ok = False
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
print(f' {domain} FAILED - {e}')
|
print(f' {domain} {click.style("FAILED", fg="red")} - {e}')
|
||||||
server_ok = False
|
server_ok = False
|
||||||
|
|
||||||
status = 'OK' if server_ok else 'FAILED'
|
if server_ok:
|
||||||
print(f' {status}\n')
|
print(f' {click.style("ALL OK", fg="green")}\n')
|
||||||
|
else:
|
||||||
|
print(f' {click.style("FAILED", fg="red")}\n')
|
||||||
|
|
||||||
|
|
||||||
def check_host_using_tilejson(*, url: str, ip: str, version: str) -> None:
|
def check_host_using_tilejson(*, url: str, ip: str, version: str) -> None:
|
||||||
|
|||||||
Reference in New Issue
Block a user