X-Git-Url: https://osm.etsi.org/gitweb/?a=blobdiff_plain;f=src%2Femuvim%2Fapi%2Frest%2Frest_api_endpoint.py;h=b5f29d49508c98703c983d3fff16853e8250573c;hb=4e37abbc1a06ffa40ed11c7c6a16c1fe95403161;hp=10b6c26fa318ea077ea7467c05a775387fa36092;hpb=ce69f2e9f813fefb0d56dfb6624e5200399becd6;p=osm%2Fvim-emu.git diff --git a/src/emuvim/api/rest/rest_api_endpoint.py b/src/emuvim/api/rest/rest_api_endpoint.py index 10b6c26..b5f29d4 100755 --- a/src/emuvim/api/rest/rest_api_endpoint.py +++ b/src/emuvim/api/rest/rest_api_endpoint.py @@ -46,7 +46,7 @@ from monitor import MonitorInterfaceAction, MonitorFlowAction, MonitorLinkAction import pkg_resources from os import path -logging.basicConfig(level=logging.INFO) +logging.basicConfig() class RestApiEndpoint(object): @@ -56,10 +56,13 @@ class RestApiEndpoint(object): default command line client. """ - def __init__(self, listenip, port): + def __init__(self, listenip, port, DCnetwork=None): self.ip = listenip self.port = port + # connect this DC network to the rest api endpoint (needed for the networking and monitoring api) + self.connectDCNetwork(DCnetwork) + # setup Flask # find directory of dashboard files dashboard_file = pkg_resources.resource_filename('emuvim.dashboard', "index.html")