-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
69 lines (63 loc) · 1.86 KB
/
docker-compose.yml
File metadata and controls
69 lines (63 loc) · 1.86 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
version: '3.8'
services:
app:
container_name: app
stdin_open: true
tty: true # Enabled together with stdin_open so it won't raise an error when we are in pdb mode.
build:
context: .
dockerfile: Dockerfile
# initialize database, then run dummy command to keep container running
command: /bin/bash -c "python /app/init_db.py && tail -f /dev/null"
volumes:
- .:/app
networks:
- btc-network
ports:
- "5000:5000"
depends_on:
- btc_janus
- btc_postgres
btc_postgres:
container_name: btc_postgres
image: postgres
shm_size: 1g
restart: unless-stopped
networks:
- btc-network
ports:
- "${DATABASE_PORT}:${DATABASE_PORT}"
volumes:
- ${DATABASE_FOLDER:-./data/btc_postgres}:/var/lib/postgresql/data
environment:
- POSTGRES_DB=${DATABASE_NAME}
- POSTGRES_USER=${DATABASE_USER}
- POSTGRES_PASSWORD=${DATABASE_PASSWORD}
btc_janus:
build:
context: ./janusgraph/
container_name: btc_janus
shm_size: 2g
ports:
- "${JANUSGRAPH_PORT:-8182}:${JANUSGRAPH_PORT:-8182}"
- "8484:8184"
- "8081:8081"
networks:
- btc-network
volumes:
- ${GRAPH_DB_FOLDER:-./data/btc_janus}:/var/lib/janusgraph
healthcheck:
test: ["CMD", "bin/gremlin.sh", "-e", "scripts/remote-connect.groovy"]
interval: 10s
timeout: 60s
retries: 4
environment:
janusgraph.storage.backend: berkeleyje
janusgraph.tx.log-tx: true
janusgraph.tx.max-commit-time: 100000000000
# janusgraph.graph.set-vertex-id: true
# janusgraph.graph.allow-custom-vid-types: true
networks:
btc-network:
# JanusGraph Failure Recovery:
# JanusGraphFactory.startTransactionRecovery(graph, java.time.Instant.now().minusSeconds(24 * 60 * 60));