mirror of
https://github.com/jupyterhub/the-littlest-jupyterhub.git
synced 2025-12-18 21:54:05 +08:00
@@ -91,10 +91,16 @@ For more information on `tljh-config`, see [](/topic/tljh-config).
|
|||||||
4. Tell your JupyterHub to _use_ the GitHub OAuthenticator for authentication:
|
4. Tell your JupyterHub to _use_ the GitHub OAuthenticator for authentication:
|
||||||
|
|
||||||
```
|
```
|
||||||
sudo tljh-config set auth.type oauthenticator.github.GitHubOAuthenticator
|
sudo tljh-config set auth.type github
|
||||||
```
|
```
|
||||||
|
|
||||||
5. Restart your JupyterHub so that new users see these changes:
|
5. Tell JupyterHub which users to allow, if you haven't already:
|
||||||
|
|
||||||
|
```
|
||||||
|
sudo tljh-config add-item users.allowed good-user_1
|
||||||
|
```
|
||||||
|
|
||||||
|
6. Restart your JupyterHub so that new users see these changes:
|
||||||
|
|
||||||
```
|
```
|
||||||
sudo tljh-config reload
|
sudo tljh-config reload
|
||||||
|
|||||||
@@ -33,7 +33,7 @@ def test_hub_version():
|
|||||||
r = requests.get(HUB_URL + "/hub/api")
|
r = requests.get(HUB_URL + "/hub/api")
|
||||||
r.raise_for_status()
|
r.raise_for_status()
|
||||||
info = r.json()
|
info = r.json()
|
||||||
assert V("4") <= V(info["version"]) <= V("5")
|
assert V("5.1") <= V(info["version"]) <= V("6")
|
||||||
|
|
||||||
|
|
||||||
async def test_user_code_execute():
|
async def test_user_code_execute():
|
||||||
|
|||||||
@@ -199,6 +199,14 @@ def update_userlists(c, config):
|
|||||||
"""
|
"""
|
||||||
users = config["users"]
|
users = config["users"]
|
||||||
|
|
||||||
|
if (
|
||||||
|
not users["allowed"]
|
||||||
|
and config["auth"]["type"] == default["auth"]["type"]
|
||||||
|
and "allow_all" not in c.FirstUseAuthenticator
|
||||||
|
):
|
||||||
|
# _default_ authenticator, enable allow_all if no users specified
|
||||||
|
c.FirstUseAuthenticator.allow_all = True
|
||||||
|
|
||||||
c.Authenticator.allowed_users = set(users["allowed"])
|
c.Authenticator.allowed_users = set(users["allowed"])
|
||||||
c.Authenticator.blocked_users = set(users["banned"])
|
c.Authenticator.blocked_users = set(users["banned"])
|
||||||
c.Authenticator.admin_users = set(users["admin"])
|
c.Authenticator.admin_users = set(users["admin"])
|
||||||
|
|||||||
@@ -8,7 +8,7 @@
|
|||||||
# If a dependency is bumped to a new major version, we should make a major
|
# If a dependency is bumped to a new major version, we should make a major
|
||||||
# version release of tljh.
|
# version release of tljh.
|
||||||
#
|
#
|
||||||
jupyterhub>=4.0.2,<5
|
jupyterhub>=5.1.0,<6
|
||||||
jupyterhub-systemdspawner>=1.0.1,<2
|
jupyterhub-systemdspawner>=1.0.1,<2
|
||||||
jupyterhub-firstuseauthenticator>=1.0.0,<2
|
jupyterhub-firstuseauthenticator>=1.0.0,<2
|
||||||
jupyterhub-nativeauthenticator>=1.2.0,<2
|
jupyterhub-nativeauthenticator>=1.2.0,<2
|
||||||
|
|||||||
Reference in New Issue
Block a user