Repository navigation
Expand file tree
/
Copy pathdocker-compose.dgraph.yml
More file actions
71 lines (68 loc) · 1.94 KB
/
Copy pathdocker-compose.dgraph.yml
File metadata and controls
71 lines (68 loc) · 1.94 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
services:
dgraph:
image: dgraph/standalone:v25.3.0
container_name: dgraph
restart: unless-stopped
environment:
# Cap BadgerDB cache (default size-mb=4096) so Alpha's working set stays
# well under the container/VM memory ceiling. Picked up by `dgraph alpha`
# via the DGRAPH_ALPHA_<FLAG> env convention (same as run.sh's SECURITY).
- "DGRAPH_ALPHA_CACHE=size-mb=2048; percentage=40,40,20"
deploy:
resources:
limits:
memory: 8g
ports:
- "8080:8080" # HTTP (GraphQL+/Admin)
- "9080:9080" # gRPC
volumes:
- ${DGRAPH_DATA_PATH:-./data/dgraph}:/dgraph
- ./config/dgraph/schema.graphql:/dgraph-seed/schema.graphql
- ./config/dgraph/seed_data.graphql:/dgraph-seed/seed_data.graphql
- ./config/dgraph/entrypoint.sh:/entrypoint.sh:ro
entrypoint: ["/entrypoint.sh"]
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8080/health"]
interval: 30s
timeout: 10s
retries: 5
start_period: 30s
networks:
- deepfry-net
dgraph-ratel:
image: dgraph/ratel:latest
container_name: dgraph-ratel
platform: linux/amd64
restart: unless-stopped
ports:
- "8000:8000" # Ratel UI
depends_on:
dgraph:
condition: service_healthy
networks:
- deepfry-net
whitelist-server:
build:
context: .
dockerfile: Dockerfile.whitelist-server
container_name: whitelist-server
restart: unless-stopped
ports:
- "8081:8081" # Whitelist HTTP API
volumes:
- ./config/whitelist/whitelist-server.yaml:/root/deepfry/whitelist.yaml
depends_on:
dgraph:
condition: service_healthy
healthcheck:
test: ["CMD", "wget", "-q", "--spider", "http://localhost:8081/health"]
interval: 30s
timeout: 5s
retries: 3
start_period: 60s
networks:
- deepfry-net
networks:
deepfry-net:
name: deepfry-net
driver: bridge