-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathsample.docker-compose.yml
More file actions
54 lines (51 loc) · 1.76 KB
/
sample.docker-compose.yml
File metadata and controls
54 lines (51 loc) · 1.76 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
services:
jupyterhub:
image: glcr.b-data.ch/jupyterhub/jupyterhub:${JH_VERSION}-oauth-docker
restart: always
networks:
- jupyter
- webproxy
volumes:
- ${JH_HOME:-.}/config/jupyterhub_config.py:/srv/jupyterhub/jupyterhub_config.py
- /var/run/docker.sock:/var/run/docker.sock
environment:
- DOCKER_JUPYTERLAB_IMAGE=${DOCKER_JUPYTERLAB_IMAGE}
- DOCKER_NETWORK_NAME=jupyter
- GITLAB_URL=https://gitlab.${GL_DOMAIN}
- GITLAB_CLIENT_ID=${JH_GITLAB_APPLICATION_ID}
- GITLAB_CLIENT_SECRET=${JH_GITLAB_SECRET}
- JPY_COOKIE_SECRET=${JH_COOKIE_SECRET}
- JUPYTERHUB_DOMAIN=${JH_DOMAIN}
- JUPYTERHUB_SUBDOMAIN=${JH_SUBDOMAIN:-jupyter}
- POSTGRES_HOST=jupyterhub-postgres
env_file:
- db.env
depends_on:
- jupyterhub-postgres
labels:
- traefik.enable=true
- traefik.docker.network=webproxy
- traefik.http.services.jupyterhub.loadbalancer.server.port=8000
- traefik.http.routers.jupyterhub.entrypoints=web
- traefik.http.routers.jupyterhub.rule=Host(`${JH_SUBDOMAIN}.${JH_DOMAIN}`)
- traefik.http.routers.jupyterhub.middlewares=http2https@file
- traefik.http.routers.jupyterhub-sec.entrypoints=websecure
- traefik.http.routers.jupyterhub-sec.rule=Host(`${JH_SUBDOMAIN}.${JH_DOMAIN}`)
- traefik.http.routers.jupyterhub-sec.tls.certresolver=${JH_CERTRESOLVER_NAME}
- traefik.http.routers.jupyterhub-sec.middlewares=sts@file
jupyterhub-postgres:
image: postgres:16-alpine
restart: always
networks:
- jupyter
env_file:
- db.env
volumes:
- jupyterhub-postgres-data:/var/lib/postgresql/data
networks:
jupyter:
external: true
webproxy:
external: true
volumes:
jupyterhub-postgres-data: