From d0bbf3b8952379883550c6eb2062476a6d15043e Mon Sep 17 00:00:00 2001 From: pkaralis Date: Thu, 6 Dec 2018 00:43:12 +0200 Subject: Enable Web Portal for ONAP results The web portal needs to be able to read test results of the ONAP compliance program and display them. In order for the above goal to be achieved, the following two parts should be impacted: 1- A new front-end should be prepared in order to handle and display the results 2- The REST API should be extended in order to support the aforementioned operation. JIRA: DOVETAIL-669 Change-Id: I36bbb6e602a67020d7e27aedbfc776f5cf4f3dc3 Signed-off-by: pkaralis Co-Authored-By: Stamatis Katsaounis --- opnfv_testapi/cmd/server.py | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'opnfv_testapi/cmd') diff --git a/opnfv_testapi/cmd/server.py b/opnfv_testapi/cmd/server.py index fee5877..5dcc60a 100644 --- a/opnfv_testapi/cmd/server.py +++ b/opnfv_testapi/cmd/server.py @@ -31,6 +31,7 @@ TODOs : import tornado.ioloop import logging +import sys from opnfv_testapi.common.config import CONF from opnfv_testapi.router import url_mappings @@ -42,12 +43,19 @@ handler = logging.handlers.RotatingFileHandler( my_logger.setLevel(logging.DEBUG) my_logger.addHandler(handler) +ch = logging.StreamHandler(sys.stdout) +ch.setLevel(logging.DEBUG) +formatter = logging.Formatter( + '%(asctime)s - %(name)s - %(levelname)s - %(message)s') +ch.setFormatter(formatter) +my_logger.addHandler(ch) + def make_app(): swagger.docs(base_url=CONF.swagger_base_url, static_path=CONF.ui_static_path) return swagger.Application( - url_mappings.mappings, + url_mappings.mappings + url_mappings.onap_mappings, debug=CONF.api_debug, auth=CONF.api_authenticate, cookie_secret='opnfv-testapi', -- cgit 1.2.3-korg