mirror of
https://github.com/balkian/jupyterhub-oauth.git
synced 2024-12-22 03:58:13 +00:00
85eab8aacc
* Pip install from submodule instead of git * Updated README * JPY_COOKIE_SECRET * DATASET (Read only) and common (Write) folders
1.3 KiB
1.3 KiB
OAuthenticator
Example of running JupyterHub with GitHub OAuth for authentication.
Variables
General variables
ADMINS=balkian,oaraque
OAUTH_CALLBACK_URL=http://hub.cluster.gsi.dit.upm.es/hub/oauth_callback
HOST_HOMEDIR=/mnt/home/{username} # {username} will be replaced by the actual OAuth user
Gitlab variables:
GITLAB_HOST=https://lab.cluster.gsi.dit.upm.es/
GITLAB_CLIENT_ID=TheMaxiID
GITLAB_CLIENT_SECRET=TheMaxiSecret
OAUTH_CLASS=oauthenticator.gitlab.GitLabOAuthenticator
DATASETS_DIR=/home/datasets # READ ONLY
COMMON_DIR=/home/common # To share files between users
GitHub variables:
GITHUB_CLIENT_ID=GHId
GITHUB_CLIENT_SECRET=GHSecret
OAUTH_CLASS=oauthenticator.github.GitHubOAuthenticator
build
Build the container with:
make build
Alternatively:
docker build -t gsiupm/jupyter-oauth:testing .
ssl
To run the server on HTTPS, put your ssl key and cert in ssl/ssl.key and ssl/ssl.cert.
run
Add your oauth client id, client secret, and callback URL to your env file
(i.e. .env
).
Once you have built the container, you can run it with:
make run
Alternatively:
docker run -it -p 8000:8000 --env-file=env gsiupm/jupyter-oauth:testing
Which will run the Jupyter server.