-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
97 lines (91 loc) · 2.35 KB
/
docker-compose.yml
File metadata and controls
97 lines (91 loc) · 2.35 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
version: '3.8'
services:
# PostgreSQL Database
postgres:
image: postgres:15-alpine
environment:
POSTGRES_DB: filevault
POSTGRES_USER: filevault_user
POSTGRES_PASSWORD: filevault_password
ports:
- "5432:5432"
volumes:
- postgres_data:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U filevault_user -d filevault"]
interval: 5s
timeout: 5s
retries: 5
# MinIO Object Storage
minio:
image: minio/minio:latest
command: server /data --console-address ":9001"
environment:
MINIO_ROOT_USER: minioadmin
MINIO_ROOT_PASSWORD: password123
ports:
- "9000:9000" # MinIO API
- "9001:9001" # MinIO Console
volumes:
- minio_data:/data
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:9000/minio/health/live"]
interval: 30s
timeout: 20s
retries: 3
# Backend API
backend:
build:
context: ./Backend
dockerfile: Dockerfile.railway
environment:
DB_HOST: postgres
DB_PORT: 5432
DB_USER: filevault_user
DB_PASSWORD: filevault_password
DB_NAME: filevault
DB_SSL_MODE: disable
SERVER_PORT: 8080
GIN_MODE: debug
MINIO_ENDPOINT: minio:9000
MINIO_ACCESS_KEY: minioadmin
MINIO_SECRET_KEY: password123
MINIO_BUCKET: files
MINIO_USE_SSL: false
RATE_LIMIT_ENABLED: true
RATE_LIMIT_PER_SECOND: 10.0
RATE_LIMIT_BURST_SIZE: 20
DEFAULT_STORAGE_QUOTA_MB: 1000
MAX_STORAGE_QUOTA_MB: 10240
# Add your Clerk keys here
CLERK_SECRET_KEY: ${CLERK_SECRET_KEY:-your_clerk_secret_key_here}
ports:
- "8080:8080"
depends_on:
postgres:
condition: service_healthy
minio:
condition: service_healthy
volumes:
- ./Backend/.env:/app/.env:ro
# Frontend
frontend:
build:
context: ./Frontend
dockerfile: Dockerfile.railway
environment:
VITE_API_URL: http://localhost:8080/api/v1
VITE_CLERK_PUBLISHABLE_KEY: ${VITE_CLERK_PUBLISHABLE_KEY:-your_clerk_publishable_key_here}
ports:
- "3000:80"
depends_on:
- backend
# MinIO Bucket Setup (runs once to create bucket)
minio-setup:
image: minio/mc:latest
depends_on:
minio:
condition: service_healthy
volumes:
postgres_data:
minio_data: