-
-
Notifications
You must be signed in to change notification settings - Fork 348
Expand file tree
/
Copy pathdocker-compose.api.yml
More file actions
79 lines (74 loc) · 2.02 KB
/
Copy pathdocker-compose.api.yml
File metadata and controls
79 lines (74 loc) · 2.02 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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
services:
bookbrainz-api:
container_name: bookbrainz-api
command: yarn run start-api
build:
context: ./
dockerfile: Dockerfile
target: bookbrainz-dev
restart: unless-stopped
ports:
- "9098:9098"
depends_on:
# elasticsearch:
# condition: service_healthy
redis:
condition: service_healthy
postgres:
condition: service_healthy
volumes:
- "./config/config.json:/home/bookbrainz/bookbrainz-site/config/config.json:ro"
postgres:
container_name: postgres
restart: unless-stopped
image: postgres:18
user: postgres
ports:
- "127.0.0.1:5432:5432"
environment:
- POSTGRES_DB=bookbrainz
- POSTGRES_USER=bookbrainz
- POSTGRES_PASSWORD=bookbrainz
volumes:
- postgres-data:/var/lib/postgresql
healthcheck:
test: ["CMD-SHELL", "pg_isready -U bookbrainz -d bookbrainz"]
interval: 5s
timeout: 3s
retries: 20
start_period: 10s
# elasticsearch:
# container_name: elasticsearch
# restart: unless-stopped
# image: docker.elastic.co/elasticsearch/elasticsearch:5.6.8
# environment:
# # Skip bootstrap checks (see https://github.com/docker-library/elasticsearch/issues/98)
# - transport.host=127.0.0.1
# - discovery.zen.minimum_master_nodes=1
# ports:
# - "9200:9200"
# volumes:
# - elasticsearch-data:/usr/share/elasticsearch/data
# healthcheck:
# test: ["CMD-SHELL", "curl -fsS 'http://localhost:9200/_cluster/health?wait_for_status=yellow&timeout=5s' || exit 1"]
# interval: 10s
# timeout: 5s
# retries: 20
# start_period: 20s
redis:
container_name: redis
restart: unless-stopped
image: redis:3.2-alpine
command: "redis-server --appendonly yes"
ports:
- "6379:6379"
- "3600:3600"
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 5s
timeout: 3s
retries: 20
start_period: 5s
volumes:
postgres-data:
# elasticsearch-data: