Add some basic endpoints to the config app backend

rename files to avoid overlap with quay app
This commit is contained in:
Sam Chow 2018-05-21 17:02:38 -04:00
parent d080ca2cc6
commit c378e408ef
39 changed files with 3095 additions and 384 deletions

View file

@ -1,17 +1,23 @@
from flask import Blueprint
from common import render_page_template
from config_app.config_endpoints.common import generate_route_data
from util.cache import no_cache
from config_endpoints.common import render_page_template
from config_endpoints.api.discovery import generate_route_data
# from config_util.cache import no_cache
setup_web = Blueprint('setup_web', __name__, template_folder='templates')
# @lru_cache(maxsize=1)
def _get_route_data():
return generate_route_data()
def render_page_template_with_routedata(name, *args, **kwargs):
return render_page_template(name, generate_route_data(), *args, **kwargs)
return render_page_template(name, _get_route_data(), *args, **kwargs)
# @no_cache
@setup_web.route('/', methods=['GET'], defaults={'path': ''})
@no_cache
def index(path, **kwargs):
return render_page_template_with_routedata('index.html', js_bundle_name='configapp', **kwargs)