-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
45 lines (43 loc) · 1.21 KB
/
docker-compose.yml
File metadata and controls
45 lines (43 loc) · 1.21 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
services:
homesec:
build: .
image: leva/homesec:latest
pull_policy: always
container_name: homesec
restart: unless-stopped
depends_on:
postgres:
condition: service_healthy
ports:
- "8081:8081"
tmpfs:
- /tmp/homesec-preview:size=${HOMESEC_PREVIEW_TMPFS_SIZE:-256m}
volumes:
- ./config/config.yaml:/config/config.yaml:ro
- ./.env:/config/.env:ro
- ./recordings:/data/recordings
- ./storage:/data/storage
- ./yolo_cache:/app/yolo_cache
environment:
- DB_DSN=postgresql+asyncpg://${POSTGRES_USER:-homesec}:${POSTGRES_PASSWORD:-homesec}@postgres:5432/${POSTGRES_DB:-homesec}
env_file:
- .env
postgres:
image: postgres:16
container_name: homesec_postgres
restart: unless-stopped
environment:
POSTGRES_USER: ${POSTGRES_USER:-homesec}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-homesec}
POSTGRES_DB: ${POSTGRES_DB:-homesec}
ports:
- "${POSTGRES_PORT:-5432}:5432"
volumes:
- homesec_pgdata:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U ${POSTGRES_USER:-homesec}"]
interval: 5s
timeout: 5s
retries: 5
volumes:
homesec_pgdata: