-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.prod.yml
75 lines (68 loc) · 1.71 KB
/
docker-compose.prod.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
64
65
66
67
68
69
70
71
72
73
74
75
name: otomad-database-api-prod
version: "3.9"
services:
api:
build:
context: ./.
dockerfile: Dockerfile
depends_on:
postgres:
condition: service_healthy
migration:
condition: service_completed_successfully
neo4j:
condition: service_healthy
environment:
PRISMA_DATABASE_URL: "postgres://user:pass@postgres:5432/test"
NEO4J_URL: "bolt://neo4j:7687"
NEO4J_USERNAME: "neo4j"
NEO4J_PASSWORD: "password"
ENABLE_GRAPHIQL: "true"
ENABLE_INTROSPECTION: "true"
ports:
- target: 8080
published: 4000
postgres:
image: postgres:15@sha256:ea40a028dd42740d6cff34135ff6b3119ff7ce0ed60120d992216456b5987fe7
healthcheck:
test: pg_isready
interval: 10s
timeout: 5s
retries: 5
environment:
POSTGRES_USER: user
POSTGRES_PASSWORD: pass
POSTGRES_DB: test
volumes:
- type: volume
source: postgres_data
target: /var/lib/postgresql/data
# migration:
# build:
# context: ./.
# dockerfile: Dockerfile.migration
# depends_on:
# postgres:
# condition: service_healthy
# environment:
# PRISMA_DATABASE_URL: "postgres://user:pass@postgres:5432/test"
neo4j:
image: neo4j:5.15@sha256:d9e2fb1ba398536e50d22ebc3d5d585baa086c1c0cf8e5b96bdc9e11e87e002a
environment:
NEO4J_AUTH: neo4j/password
healthcheck:
test: neo4j status || exit 1 # TODO:
interval: 10s
timeout: 5s
retries: 5
volumes:
- type: volume
source: neo4j_data
target: /data
- type: volume
source: neo4j_logs
target: /logs
volumes:
postgres_data:
neo4j_data:
neo4j_logs: