| Index: appengine/config_service/handlers.py
|
| diff --git a/appengine/config_service/handlers.py b/appengine/config_service/handlers.py
|
| index 3a6e135477939404fbabc8a086c5f0171803e6e0..c7dc8c4fb900bb10a38aa43b783c9a1d564e589a 100644
|
| --- a/appengine/config_service/handlers.py
|
| +++ b/appengine/config_service/handlers.py
|
| @@ -8,10 +8,12 @@ import webapp2
|
|
|
| from components import decorators
|
| from components.config.proto import service_config_pb2
|
| +from google.appengine.ext.webapp import template
|
|
|
| import common
|
| import gitiles_import
|
| import notifications
|
| +import os
|
| import storage
|
|
|
|
|
| @@ -28,6 +30,19 @@ class MainPageHandler(webapp2.RequestHandler):
|
| def get(self):
|
| self.redirect('_ah/api/explorer')
|
|
|
| +class UIHandler(webapp2.RequestHandler):
|
| + """ Serves the UI with the proper client ID. """
|
| +
|
| + def get(self):
|
| + # TODO(cwpayton): put the client_id in a proto file so that it is
|
| + # configurable and can be read dynamically by this file.
|
| + template_values = {
|
| + 'client_id':
|
| + '247108661754-svmo17vmk1j5hlt388gb45qblgvg2h98.apps.googleusercontent.com'
|
| + }
|
| + path = os.path.join(os.path.dirname(__file__), 'ui/static/index.html')
|
| + self.response.out.write(template.render(path, template_values))
|
| +
|
|
|
| class SchemasHandler(webapp2.RequestHandler):
|
| """Redirects to a known schema definition."""
|
| @@ -51,6 +66,7 @@ class SchemasHandler(webapp2.RequestHandler):
|
| def get_frontend_routes(): # pragma: no cover
|
| return [
|
| webapp2.Route(r'/', MainPageHandler),
|
| + webapp2.Route(r'/newui', UIHandler),
|
| webapp2.Route(r'/schemas/<name:.+>', SchemasHandler),
|
| webapp2.Route(r'/_ah/bounce', notifications.BounceHandler),
|
| ]
|
|
|