mirror of
https://github.com/checktheroads/hyperglass
synced 2024-05-11 05:55:08 +00:00
Minor improvements
This commit is contained in:
1
.gitignore
vendored
1
.gitignore
vendored
@@ -2,6 +2,7 @@ test.py
|
|||||||
.DS_Store
|
.DS_Store
|
||||||
.idea
|
.idea
|
||||||
.vscode
|
.vscode
|
||||||
|
old_*.py
|
||||||
#
|
#
|
||||||
# Github Default from https://github.com/martinohanlon/flightlight/issues/1
|
# Github Default from https://github.com/martinohanlon/flightlight/issues/1
|
||||||
# Byte-compiled / optimized / DLL files
|
# Byte-compiled / optimized / DLL files
|
||||||
|
@@ -1,6 +1,7 @@
|
|||||||
"""hyperglass REST API & Web UI."""
|
"""hyperglass REST API & Web UI."""
|
||||||
|
|
||||||
# Standard Library
|
# Standard Library
|
||||||
|
import sys
|
||||||
from typing import List
|
from typing import List
|
||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
|
|
||||||
@@ -265,4 +266,7 @@ def start(**kwargs):
|
|||||||
"""Start the web server with Uvicorn ASGI."""
|
"""Start the web server with Uvicorn ASGI."""
|
||||||
import uvicorn
|
import uvicorn
|
||||||
|
|
||||||
uvicorn.run("hyperglass.api:app", **ASGI_PARAMS, **kwargs)
|
try:
|
||||||
|
uvicorn.run("hyperglass.api:app", **ASGI_PARAMS, **kwargs)
|
||||||
|
except KeyboardInterrupt:
|
||||||
|
sys.exit(1)
|
||||||
|
@@ -23,7 +23,7 @@ class _IPv6(CommandSet):
|
|||||||
bgp_community: StrictStr = "show bgp ipv6 unicast community {target}"
|
bgp_community: StrictStr = "show bgp ipv6 unicast community {target}"
|
||||||
bgp_aspath: StrictStr = 'show bgp ipv6 unicast quote-regexp "{target}"'
|
bgp_aspath: StrictStr = 'show bgp ipv6 unicast quote-regexp "{target}"'
|
||||||
bgp_route: StrictStr = "show bgp ipv6 unicast {target} | exclude pathid:|Epoch"
|
bgp_route: StrictStr = "show bgp ipv6 unicast {target} | exclude pathid:|Epoch"
|
||||||
ping: StrictStr = ("ping ipv6 {target} repeat 5 source {source}")
|
ping: StrictStr = "ping ipv6 {target} repeat 5 source {source}"
|
||||||
traceroute: StrictStr = (
|
traceroute: StrictStr = (
|
||||||
"traceroute ipv6 {target} timeout 1 probe 2 source {source}"
|
"traceroute ipv6 {target} timeout 1 probe 2 source {source}"
|
||||||
)
|
)
|
||||||
|
Reference in New Issue
Block a user