Skip to content

Commit

Permalink
Add docs service api token
Browse files Browse the repository at this point in the history
  • Loading branch information
GeorgianaElena committed Jun 2, 2021
1 parent 76c15bf commit b246cbc
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion deployer/hub.py
Original file line number Diff line number Diff line change
Expand Up @@ -294,9 +294,11 @@ def apply_hub_template_fixes(self, generated_config, secret_key):

}

docs_token = hmac.new(secret_key, f'docs-{self.spec["name"]}'.encode(), hashlib.sha256).hexdigest()
if 'docs_service' in self.spec['config'].keys() and self.spec['config']['docs_service']['enabled']:
generated_config['jupyterhub']['hub']['services']['docs'] = {
'url': f'http://docs-service.{self.spec["name"]}'
'url': f'http://docs-service.{self.spec["name"]}',
'apiToken': docs_token
}


Expand Down

0 comments on commit b246cbc

Please sign in to comment.