-
Notifications
You must be signed in to change notification settings - Fork 11
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
55 lines (52 loc) · 1.44 KB
/
docker-compose.yml
File metadata and controls
55 lines (52 loc) · 1.44 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
55
include:
- docker-compose-db.yml
services:
backend:
build:
context: .
dockerfile: Dockerfile.backend
container_name: docent_backend
ports:
- "${DOCENT_SERVER_PORT:-8888}:${DOCENT_SERVER_PORT:-8888}"
depends_on:
- postgres
- redis
# Uncomment to forward SSH agent to the container
# volumes:
# - ${SSH_AUTH_SOCK}:/ssh-agent
# environment:
# - SSH_AUTH_SOCK=/ssh-agent
environment:
- ENV_RESOLUTION_STRATEGY=os_environ
- DOCENT_PG_HOST=postgres
- DOCENT_REDIS_HOST=redis
command: bash -c "docent_core server --port ${DOCENT_SERVER_PORT:-8888} --workers 8"
restart: unless-stopped
worker:
build:
context: .
dockerfile: Dockerfile.backend
container_name: docent_worker
depends_on:
- postgres
- redis
environment:
- ENV_RESOLUTION_STRATEGY=os_environ
- DOCENT_PG_HOST=postgres
- DOCENT_REDIS_HOST=redis
command: bash -c "docent_core worker --workers 2"
restart: unless-stopped
frontend:
build:
context: .
dockerfile: Dockerfile.frontend
args:
- NEXT_PUBLIC_API_HOST=${DOCENT_HOST:-http://localhost}:${DOCENT_SERVER_PORT:-8888}
container_name: docent_frontend
ports:
- "${DOCENT_WEB_PORT:-3000}:3000"
depends_on:
- backend
environment:
- NEXT_PUBLIC_INTERNAL_API_HOST=http://backend:${DOCENT_SERVER_PORT:-8888}
restart: unless-stopped