-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
80 lines (75 loc) · 2.28 KB
/
docker-compose.yml
File metadata and controls
80 lines (75 loc) · 2.28 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
72
73
74
75
76
77
78
79
80
services:
database:
image: postgres:17-alpine
restart: unless-stopped
command: ["postgres", "-c", "wal_level=logical"]
environment:
POSTGRES_USER: ${POSTGRES_USER}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
POSTGRES_DB: ${POSTGRES_DB}
volumes:
- postgres_data:/var/lib/postgresql/data
ports:
- "${POSTGRES_PORT}:5432"
healthcheck:
test: ["CMD-SHELL", "pg_isready -U ${POSTGRES_USER}"]
interval: 5s
timeout: 5s
retries: 5
powersync-storage:
image: postgres:17-alpine
restart: unless-stopped
environment:
POSTGRES_USER: ${POWERSYNC_STORAGE_USER}
POSTGRES_PASSWORD: ${POWERSYNC_STORAGE_PASSWORD}
POSTGRES_DB: ${POWERSYNC_STORAGE_DB}
volumes:
- powersync_storage_data:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U ${POWERSYNC_STORAGE_USER} -d ${POWERSYNC_STORAGE_DB}"]
interval: 5s
timeout: 5s
retries: 5
mailpit:
image: axllent/mailpit:v1.26
restart: unless-stopped
ports:
- "1025:1025"
- "8025:8025"
powersync:
image: journeyapps/powersync-service:latest
restart: unless-stopped
command: ["start", "-r", "unified"]
extra_hosts:
- "host.docker.internal:host-gateway"
environment:
POWERSYNC_CONFIG_PATH: /config/service.yaml
PS_DATA_SOURCE_URI: postgresql://${POWERSYNC_SOURCE_ROLE}:${POWERSYNC_SOURCE_PASSWORD}@database:5432/${POSTGRES_DB}
PS_STORAGE_URI: postgresql://${POWERSYNC_STORAGE_USER}:${POWERSYNC_STORAGE_PASSWORD}@powersync-storage:5432/${POWERSYNC_STORAGE_DB}
PS_JWKS_URI: ${POWERSYNC_JWKS_URI:-http://host.docker.internal:8080/v1/auth/jwks}
PS_AUDIENCE: ${POWERSYNC_JWT_AUDIENCE}
volumes:
- ./powersync:/config:ro
ports:
- "${POWERSYNC_SERVICE_PORT:-8081}:8080"
depends_on:
database:
condition: service_healthy
powersync-storage:
condition: service_healthy
server:
build: .
restart: unless-stopped
ports:
- "${PORT:-8080}:8080"
env_file: .env
depends_on:
database:
condition: service_healthy
mailpit:
condition: service_started
command: >
sh -c "alembic upgrade head && papyrus-server"
volumes:
postgres_data:
powersync_storage_data: