Skip to content
Snippets Groups Projects
Commit 9c883a7d authored by Jonathan Villemaire-Krajden's avatar Jonathan Villemaire-Krajden
Browse files

Fixes to urls and change listening port.

parent 06aac3e2
No related branches found
No related tags found
No related merge requests found
......@@ -10,7 +10,7 @@ from tornado.web import RequestHandler, Application, authenticated
class AccessTokenHandler(HubAuthenticated, RequestHandler):
''' Respond to Access Token requests. '''
async def _request_token(self, username: str) -> str:
user_endpoint = self.api_url + f'/users/{username}'
user_endpoint = f'{self.api_url}/users/{username}'
headers = {
'Authorization': f'token {self.api_token}',
}
......@@ -28,7 +28,7 @@ class AccessTokenHandler(HubAuthenticated, RequestHandler):
def main():
prefix = os.environ.get('JUPYTERHUB_SERVICE_PREFIX', '')
app = Application([
(prefix + '/oauth_token', AccessTokenHandler),
(prefix + 'oauth_token', AccessTokenHandler),
])
app.listen(8080)
app.listen(8528)
tornado.ioloop.IOLoop.current().start()
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment