-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
executable file
·73 lines (69 loc) · 1.92 KB
/
Copy pathdocker-compose.yml
File metadata and controls
executable file
·73 lines (69 loc) · 1.92 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
services:
db:
image: pgvector/pgvector:pg16
container_name: facevector_engine_db
environment:
POSTGRES_USER: ${POSTGRES_USER}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
POSTGRES_DB: ${POSTGRES_DB}
ports:
- "5432:5432"
volumes:
- pgdata:/var/lib/postgresql/data
command: ["postgres", "-c", "shared_preload_libraries=vector"]
healthcheck:
test: ["CMD-SHELL", "pg_isready -U ${POSTGRES_USER}"]
interval: 5s
timeout: 5s
retries: 5
networks:
- facevector-network
rustfs:
image: rustfs/rustfs:latest
container_name: facevector_engine_rustfs
ports:
- "9000:9000" # API
- "9001:9001" # Console UI
environment:
RUSTFS_ADDRESS: ":9000"
RUSTFS_ACCESS_KEY: ${S3_ACCESS_KEY:-rustfsadmin}
RUSTFS_SECRET_KEY: ${S3_SECRET_KEY:-rustfsadmin}
RUSTFS_CONSOLE_ENABLE: "true"
command: ["/data"]
volumes:
- rustfs-data:/data
healthcheck:
test: ["CMD", "curl", "-sS", "-o", "/dev/null", "http://localhost:9000/rustfs/health/live"]
interval: 5s
timeout: 5s
retries: 12
networks:
- facevector-network
api:
build: .
container_name: facevector_engine_api
environment:
DATABASE_URL: postgres://${POSTGRES_USER}:${POSTGRES_PASSWORD}@db:5432/${POSTGRES_DB}
PORT: ${PORT}
# S3/RustFS Configuration
S3_ENDPOINT: http://rustfs:9000
S3_BUCKET: ${S3_BUCKET:-facevector-engine}
S3_ACCESS_KEY: ${S3_ACCESS_KEY:-rustfsadmin}
S3_SECRET_KEY: ${S3_SECRET_KEY:-rustfsadmin}
S3_REGION: ${S3_REGION:-us-east-1}
S3_FORCE_PATH_STYLE: ${S3_FORCE_PATH_STYLE:-true}
ports:
- "${PORT}:${PORT}"
depends_on:
db:
condition: service_healthy
rustfs:
condition: service_healthy
networks:
- facevector-network
volumes:
pgdata:
rustfs-data:
networks:
facevector-network:
driver: bridge