-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
63 lines (60 loc) · 1.45 KB
/
docker-compose.yml
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
networks:
galaxydb-network:
name: galaxydb-network
driver: bridge
services:
galaxydb-metadata:
image: postgres
environment:
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=galaxydb
- POSTGRES_DB=postgres
- PGPORT=5432
- PGHOST=galaxydb-metadata
networks:
- galaxydb-network
volumes:
- ./loadbalancer/init.sql:/docker-entrypoint-initdb.d/init.sql
healthcheck:
test: ["CMD", "pg_isready", "-U", "postgres"]
interval: 5s
timeout: 3s
retries: 20
galaxydb-loadbalancer:
build:
context: ./loadbalancer
dockerfile: Dockerfile.lb
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- ./server:/server
image: galaxydb-lb
ports:
- "5000:5000"
privileged: true
networks:
- galaxydb-network
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:5000/serverids"]
interval: 5s
timeout: 3s
retries: 20
depends_on:
galaxydb-metadata:
condition: service_healthy
galaxydb-shard-manager:
build:
context: ./loadbalancer
dockerfile: Dockerfile.manager
volumes:
- /var/run/docker.sock:/var/run/docker.sock
image: galaxydb-shard-manager
ports:
- "8000:8000"
privileged: true
networks:
- galaxydb-network
depends_on:
galaxydb-metadata:
condition: service_healthy
galaxydb-loadbalancer:
condition: service_healthy