mirror of
https://github.com/jupyterhub/jupyterhub.git
synced 2025-10-18 15:33:02 +00:00
Merge pull request #4161 from Christiandike/update/separate-proxy.md
Improve text in proxy docs
This commit is contained in:
@@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
## Background
|
## Background
|
||||||
|
|
||||||
The thing which users directly connect to is the proxy, by default
|
The thing which users directly connect to is the proxy, which by default is
|
||||||
`configurable-http-proxy`. The proxy either redirects users to the
|
`configurable-http-proxy`. The proxy either redirects users to the
|
||||||
hub (for login and managing servers), or to their own single-user
|
hub (for login and managing servers), or to their own single-user
|
||||||
servers. Thus, as long as the proxy stays running, access to existing
|
servers. Thus, as long as the proxy stays running, access to existing
|
||||||
@@ -10,16 +10,15 @@ servers continues, even if the hub itself restarts or goes down.
|
|||||||
|
|
||||||
When you first configure the hub, you may not even realize this
|
When you first configure the hub, you may not even realize this
|
||||||
because the proxy is automatically managed by the hub. This is great
|
because the proxy is automatically managed by the hub. This is great
|
||||||
for getting started and even most use, but everytime you restart the
|
for getting started and even most use-cases, although, everytime you restart the
|
||||||
hub, all user connections also get restarted. But it's also simple to
|
hub, all user connections are also restarted. However, it is also simple to
|
||||||
run the proxy as a service separate from the hub, so that you are free
|
run the proxy as a service separate from the hub, so that you are free
|
||||||
to reconfigure the hub while only interrupting users who are currently
|
to reconfigure the hub while only interrupting users who are currently
|
||||||
actively starting the hub.
|
actively starting the hub.
|
||||||
|
|
||||||
The default JupyterHub proxy is
|
The default JupyterHub proxy is
|
||||||
[configurable-http-proxy](https://github.com/jupyterhub/configurable-http-proxy),
|
[configurable-http-proxy](https://github.com/jupyterhub/configurable-http-proxy). If you are using a different proxy, such
|
||||||
and that page has some docs. If you are using a different proxy, such
|
as [Traefik](https://github.com/traefik/traefik), these instructions are probably not relevant to you.
|
||||||
as Traefik, these instructions are probably not relevant to you.
|
|
||||||
|
|
||||||
## Configuration options
|
## Configuration options
|
||||||
|
|
||||||
@@ -40,9 +39,14 @@ set to the URL which the hub uses to connect _to the proxy's API_.
|
|||||||
## Proxy configuration
|
## Proxy configuration
|
||||||
|
|
||||||
You need to configure a service to start the proxy. An example
|
You need to configure a service to start the proxy. An example
|
||||||
command line for this is `configurable-http-proxy --ip=127.0.0.1 --port=8000 --api-ip=127.0.0.1 --api-port=8001 --default-target=http://localhost:8081 --error-target=http://localhost:8081/hub/error`. (Details for how to
|
command line argument for this is:
|
||||||
do this is out of scope for this tutorial - for example it might be a
|
|
||||||
systemd service on within another docker cotainer). The proxy has no
|
```bash
|
||||||
|
$ configurable-http-proxy --ip=127.0.0.1 --port=8000 --api-ip=127.0.0.1 --api-port=8001 --default-target=http://localhost:8081 --error-target=http://localhost:8081/hub/error
|
||||||
|
```
|
||||||
|
|
||||||
|
(Details on how to do this is out of the scope of this tutorial. For example, it might be a
|
||||||
|
systemd service configured within another docker container). The proxy has no
|
||||||
configuration files, all configuration is via the command line and
|
configuration files, all configuration is via the command line and
|
||||||
environment variables.
|
environment variables.
|
||||||
|
|
||||||
@@ -57,9 +61,9 @@ match the token given to `c.ConfigurableHTTPProxy.auth_token`.
|
|||||||
|
|
||||||
You should check the [configurable-http-proxy
|
You should check the [configurable-http-proxy
|
||||||
options](https://github.com/jupyterhub/configurable-http-proxy) to see
|
options](https://github.com/jupyterhub/configurable-http-proxy) to see
|
||||||
what other options are needed, for example SSL options. Note that
|
what other options are needed, for example, SSL options. Note that
|
||||||
these are configured in the hub if the hub is starting the proxy - you
|
these options are configured in the hub if the hub is starting the proxy, so you
|
||||||
need to move the options to here.
|
need to configure the options there.
|
||||||
|
|
||||||
## Docker image
|
## Docker image
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user