Skip to content

Commit 9658c24

Browse files
committed
Move subdomain docs from schema to the security page
1 parent 2e926de commit 9658c24

File tree

2 files changed

+43
-10
lines changed

2 files changed

+43
-10
lines changed

docs/source/administrator/security.md

+41
Original file line numberDiff line numberDiff line change
@@ -489,3 +489,44 @@ proxy:
489489
```
490490
491491
This would restrict the access to only two IP addresses: `111.111.111.111` and `222.222.222.222`.
492+
493+
(jupyterhub_subdomains)=
494+
495+
## Host user servers on a subdomain
496+
497+
You can reduce the chance of cross-origin attacks by giving each user
498+
their own subdomain `<user>.jupyter.example.org`.
499+
This requires setting [`hub.config.subdomain_host`](schema_hub.config.subdomain_host), creating a wildcard DNS record `*.jupyter.example.org`, and creating a wildcard SSL certificate.
500+
501+
```yaml
502+
hub:
503+
config:
504+
JupyterHub:
505+
subdomain_host: jupyter.example.org
506+
```
507+
508+
If you are using a Kubernetes ingress this must include hosts
509+
`jupyter.example.org` and `*.jupyter.example.org`.
510+
For example:
511+
512+
```yaml
513+
ingress:
514+
enabled: true
515+
hosts:
516+
- jupyter.example.org
517+
- "*.jupyter.example.org"
518+
tls:
519+
- hosts:
520+
- jupyter.example.org
521+
- "*.jupyter.example.org"
522+
secretName: example-tls
523+
```
524+
525+
where `example-tls` is the name of a Kubernetes secret containing the wildcard certificate and key.
526+
527+
The chart does not support the automatic creation of wildcard HTTPS certificates.
528+
You must obtain a certificate from an external source,
529+
for example by using an ACME client such as [cert-manager with the DNS-01 challenge](https://cert-manager.io/docs/configuration/acme/dns01/),
530+
and ensure the certificate and key are stored in the secret.
531+
532+
See {ref}`jupyterhub:subdomains` in the JupyterHub documentation for more information.

jupyterhub/values.schema.yaml

+2-10
Original file line numberDiff line numberDiff line change
@@ -278,17 +278,9 @@ properties:
278278
The subdomain to use for hosting singleuser servers.
279279
280280
This helps protect against some cross-origin attacks by giving each user
281-
their own subdomain `<user>.subdomain.example.org`.
281+
their own subdomain `<user>.jupyter.example.org`.
282282
283-
It requires a wildcard DNS `*.subdomain.example.org` and SSL certificate.
284-
If you are using a Kubernetes ingress this must include hosts
285-
`subdomain.example.org` and `*.subdomain.example.org`.
286-
287-
The chart does not support the automatic creation of wildcard HTTPS certificates.
288-
Instead you should obtain a certificate from an external source,
289-
or install an ACME client such as cert-manager with the DNS-01 challenge.
290-
291-
See {ref}`jupyterhub:subdomains` in the JupyterHub documentation.
283+
See {ref}`jupyterhub_subdomains`.
292284
extraFiles: &extraFiles
293285
type: object
294286
additionalProperties: false

0 commit comments

Comments
 (0)