-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
123 lines (116 loc) · 3.87 KB
/
Copy pathdocker-compose.yml
File metadata and controls
123 lines (116 loc) · 3.87 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
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
networks:
assistant-net:
driver: bridge
volumes:
postgres-data:
redis-data:
n8n-data:
agent-videos:
services:
# ── Postgres + pgvector ──────────────────────────────────────────────────────
postgres:
image: pgvector/pgvector:pg16
container_name: assistant-postgres
restart: unless-stopped
environment:
POSTGRES_DB: ${POSTGRES_DB}
POSTGRES_USER: ${POSTGRES_USER}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
volumes:
- postgres-data:/var/lib/postgresql/data
- ./agent-core/db/init.sql:/docker-entrypoint-initdb.d/init.sql:ro
networks:
- assistant-net
healthcheck:
test: ["CMD-SHELL", "pg_isready -U ${POSTGRES_USER} -d ${POSTGRES_DB}"]
interval: 10s
timeout: 5s
retries: 5
# ── Redis ────────────────────────────────────────────────────────────────────
redis:
image: redis:7-alpine
container_name: assistant-redis
restart: unless-stopped
volumes:
- redis-data:/data
networks:
- assistant-net
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 10s
timeout: 5s
retries: 5
# ── Playwright browser service ───────────────────────────────────────────────
playwright:
build:
context: ./playwright-service
dockerfile: Dockerfile
container_name: assistant-playwright
restart: unless-stopped
networks:
- assistant-net
environment:
PORT: 3001
# ── Agent Core ───────────────────────────────────────────────────────────────
agent-core:
build:
context: ./agent-core
dockerfile: Dockerfile
container_name: assistant-agent-core
restart: unless-stopped
env_file: .env
environment:
DATABASE_URL: ${DATABASE_URL}
REDIS_URL: ${REDIS_URL}
PLAYWRIGHT_URL: http://playwright:3001
N8N_WEBHOOK_BASE_URL: ${N8N_WEBHOOK_BASE_URL}
ports:
- "8100:8000"
volumes:
- agent-videos:/app/videos
networks:
- assistant-net
depends_on:
postgres:
condition: service_healthy
redis:
condition: service_healthy
playwright:
condition: service_started
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8000/health"]
interval: 15s
timeout: 5s
retries: 5
# ── n8n ──────────────────────────────────────────────────────────────────────
n8n:
image: n8nio/n8n:latest
container_name: assistant-n8n
restart: unless-stopped
environment:
N8N_ENCRYPTION_KEY: ${N8N_ENCRYPTION_KEY}
N8N_BASIC_AUTH_ACTIVE: "true"
N8N_BASIC_AUTH_USER: ${N8N_BASIC_AUTH_USER}
N8N_BASIC_AUTH_PASSWORD: ${N8N_BASIC_AUTH_PASSWORD}
N8N_HOST: ${N8N_HOST}
N8N_PORT: ${N8N_PORT}
N8N_PROTOCOL: http
WEBHOOK_URL: http://${N8N_HOST}:${N8N_PORT}/
GENERIC_TIMEZONE: UTC
DB_TYPE: postgresdb
DB_POSTGRESDB_HOST: postgres
DB_POSTGRESDB_PORT: 5432
DB_POSTGRESDB_DATABASE: ${POSTGRES_DB}
DB_POSTGRESDB_USER: ${POSTGRES_USER}
DB_POSTGRESDB_PASSWORD: ${POSTGRES_PASSWORD}
DB_POSTGRESDB_SCHEMA: n8n
N8N_SECURE_COOKIE: "false"
ports:
- "5679:5678"
volumes:
- n8n-data:/home/node/.n8n
networks:
- assistant-net
depends_on:
postgres:
condition: service_healthy