This repository was archived by the owner on Dec 24, 2025. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathdocker-compose.deploy.yaml
More file actions
106 lines (100 loc) · 3 KB
/
docker-compose.deploy.yaml
File metadata and controls
106 lines (100 loc) · 3 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
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
services:
boreal.chat:
image: ghcr.io/wosherco/boreal.chat
ports:
- 3000:3000
environment:
PUBLIC_ENVIRONMENT: production
PUBLIC_URL: https://boreal.chat
GOOGLE_AUTH_CLIENT_ID: ""
GOOGLE_AUTH_CLIENT_SECRET: ""
GOOGLE_AUTH_REDIRECT_URI: "https://boreal.chat/auth/google/callback"
DATABASE_URL: "postgres://postgres:password@postgres:5432/borealchat"
ELECTRIC_SQL_URL: "http://electric:3000"
REDIS_URL: "redis://redis:6379"
volumes:
- .env:/app/.env
postgres:
image: postgres:16-alpine
environment:
POSTGRES_DB: borealchat
POSTGRES_USER: postgres
POSTGRES_PASSWORD: password
ports:
- 5432
volumes:
- postgres-data:/var/lib/postgresql/data
command:
- -c
- listen_addresses=*
- -c
- wal_level=logical
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres -d postgres"]
interval: 5s
timeout: 5s
retries: 5
electric:
image: electricsql/electric
environment:
DATABASE_URL: postgresql://postgres:password@postgres:5432/borealchat?sslmode=disable
# Not suitable for production. Only use insecure mode in development or if you've otherwise secured the Electric API.
# See https://electric-sql.com/docs/guides/security
ELECTRIC_INSECURE: true
ports:
- 3000
depends_on:
postgres:
condition: service_healthy
redis:
image: redis:latest
ports:
- 6379
volumes:
- redis-data:/data
minio:
image: minio/minio:latest
ports:
- 9000
- 9001
environment:
MINIO_ROOT_USER: minioadmin
MINIO_ROOT_PASSWORD: minioadmin
MINIO_REGION_NAME: us-east-1
# Webhook notification configuration
MINIO_NOTIFY_WEBHOOK_ENABLE_primary: "on"
MINIO_NOTIFY_WEBHOOK_ENDPOINT_primary: "http://boreal.chat:3000/api/webhook/s3"
MINIO_NOTIFY_WEBHOOK_AUTH_TOKEN_primary: ""
volumes:
- minio-data:/data
command: server /data --console-address ":9001"
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:9000/minio/health/live"]
interval: 30s
timeout: 20s
retries: 3
minio-setup:
image: minio/mc:latest
depends_on:
minio:
condition: service_healthy
entrypoint: >
/bin/sh -c "
echo 'Configuring MinIO webhook notifications...';
mc alias set local http://minio:9000 minioadmin minioadmin;
echo 'Creating bucket if it does not exist...';
mc mb local/borealchat-files --ignore-existing;
echo 'Setting up webhook notification...';
mc event add local/borealchat-files arn:minio:sqs::primary:webhook --event put;
echo 'Webhook notification setup complete!';
echo 'Configuration:';
echo '- Bucket: borealchat-files';
echo '- Webhook: http://boreal.chat:3000/api/webhook/s3';
echo '- Events: s3:ObjectCreated:Put';
mc event list local/borealchat-files;
"
restart: "no"
volumes:
postgres-data:
redis-data:
minio-data: