Merge pull request #1833 from rkdarst/cull_idle_py36

Note cull-idle needs python3
This commit is contained in:
Tim Head
2018-04-26 15:44:35 +02:00
committed by GitHub
4 changed files with 7 additions and 7 deletions

View File

@@ -88,7 +88,7 @@ c.JupyterHub.services = [
{
'name': 'cull-idle',
'admin': True,
'command': 'python cull_idle_servers.py --timeout=3600'.split(),
'command': 'python3 cull_idle_servers.py --timeout=3600'.split(),
}
]
```
@@ -115,7 +115,7 @@ variable. Run `cull_idle_servers.py` manually.
```bash
export JUPYTERHUB_API_TOKEN='token'
python cull_idle_servers.py [--timeout=900] [--url=http://127.0.0.1:8081/hub/api]
python3 cull_idle_servers.py [--timeout=900] [--url=http://127.0.0.1:8081/hub/api]
```
[cull_idle_servers]: https://github.com/jupyterhub/jupyterhub/blob/master/examples/cull-idle/cull_idle_servers.py

View File

@@ -15,7 +15,7 @@ c.JupyterHub.services = [
{
'name': 'cull-idle',
'admin': True,
'command': 'python cull_idle_servers.py --timeout=3600'.split(),
'command': 'python3 cull_idle_servers.py --timeout=3600'.split(),
}
]
```
@@ -37,5 +37,5 @@ variable. Run `cull_idle_servers.py` manually.
```bash
export JUPYTERHUB_API_TOKEN=`jupyterhub token`
python cull_idle_servers.py [--timeout=900] [--url=http://127.0.0.1:8081/hub/api]
python3 cull_idle_servers.py [--timeout=900] [--url=http://127.0.0.1:8081/hub/api]
```

View File

@@ -16,14 +16,14 @@ You can run this as a service managed by JupyterHub with this in your config::
{
'name': 'cull-idle',
'admin': True,
'command': 'python cull_idle_servers.py --timeout=3600'.split(),
'command': 'python3 cull_idle_servers.py --timeout=3600'.split(),
}
]
Or run it manually by generating an API token and storing it in `JUPYTERHUB_API_TOKEN`:
export JUPYTERHUB_API_TOKEN=`jupyterhub token`
python cull_idle_servers.py [--timeout=900] [--url=http://127.0.0.1:8081/hub/api]
python3 cull_idle_servers.py [--timeout=900] [--url=http://127.0.0.1:8081/hub/api]
"""
from datetime import datetime, timezone

View File

@@ -3,6 +3,6 @@ c.JupyterHub.services = [
{
'name': 'cull-idle',
'admin': True,
'command': 'python cull_idle_servers.py --timeout=3600'.split(),
'command': 'python3 cull_idle_servers.py --timeout=3600'.split(),
}
]