diff --git a/docs/source/getting-started/services-basics.md b/docs/source/getting-started/services-basics.md index 9b5aa7b1..e9e399e2 100644 --- a/docs/source/getting-started/services-basics.md +++ b/docs/source/getting-started/services-basics.md @@ -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 diff --git a/examples/cull-idle/README.md b/examples/cull-idle/README.md index ac775a58..c02320f2 100644 --- a/examples/cull-idle/README.md +++ b/examples/cull-idle/README.md @@ -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] ``` diff --git a/examples/cull-idle/cull_idle_servers.py b/examples/cull-idle/cull_idle_servers.py index 258832e5..7549f1d2 100755 --- a/examples/cull-idle/cull_idle_servers.py +++ b/examples/cull-idle/cull_idle_servers.py @@ -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 diff --git a/examples/cull-idle/jupyterhub_config.py b/examples/cull-idle/jupyterhub_config.py index 2de8f424..f8a6bf52 100644 --- a/examples/cull-idle/jupyterhub_config.py +++ b/examples/cull-idle/jupyterhub_config.py @@ -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(), } ]