-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yaml
64 lines (60 loc) · 1.88 KB
/
docker-compose.yaml
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
# This Docker Compose file can be used to quickly bootup Dgraph Zero
# and Alpha in different Docker containers.
# Data would be persisted to a Docker volume called db_data on the virtual machines.
# Run `docker-compose up` to start Dgraph.
# For ports usage, see: https://dgraph.io/docs/deploy/ports-usage/
# Check alpha state - http://localhost:8080/state
# Check alpha health - http://localhost:8080/health
version: "3.2"
services:
zero:
container_name: "dgraph-zero"
image: dgraph/dgraph:v21.03-slash
volumes:
- db_data:/dgraph
network_mode: host
ports:
- 5080 # grpc port
- 6080 # http port
restart: on-failure
command: dgraph zero --my=127.0.0.1:5080
alpha:
container_name: "dgraph-alpha"
image: dgraph/dgraph:v21.03-slash
volumes:
- db_data:/dgraph
network_mode: host
ports:
- 8080 # http port
- 7080 # grpc port
- 9080 # grpc port
restart: on-failure
command: dgraph alpha --my=127.0.0.1:7080 --zero=127.0.0.1:5080 --security "whitelist=0.0.0.0/0; token=TOP_SECRET" --graphql "debug=true; extensions=true; introspection=true; lambda-url=http://127.0.0.1:8686/graphql-worker; poll-interval=1s;"
lambda:
container_name: "dgraph-lambda"
image: dgraph/dgraph-lambda:latest
network_mode: host
ports:
- "8686"
environment:
DGRAPH_URL: http://127.0.0.1:8080
MAX_MEMORY_LIMIT: "2048M"
volumes:
- ./gql/dist/script.js:/app/script/script.js:ro
ratel:
container_name: "dgraph-ratel"
image: dgraph/ratel:latest
network_mode: host
ports:
- 8000
restart: on-failure
command: dgraph-ratel -addr=http://127.0.0.1:8080
graphql-playground:
container_name: "dgraphql-playground"
image: vtemian/graphql-playground
ports:
- "8888:80"
environment:
- GRAPHQL_ENDPOINT=http://127.0.0.1:8080/graphql
volumes:
db_data: