-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
95 lines (90 loc) · 2.6 KB
/
Copy pathdocker-compose.yml
File metadata and controls
95 lines (90 loc) · 2.6 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
# ResumeGenius Docker Compose
# 统一编排 postgres + backend + workbench + marketing
networks:
default:
ipam:
config:
- subnet: ${DOCKER_SUBNET:-10.200.0.0/16}
services:
postgres:
image: ${PGVECTOR_IMAGE:-docker.1ms.run/ankane/pgvector:latest}
environment:
POSTGRES_DB: ${POSTGRES_DB:-resume_genius}
POSTGRES_USER: ${POSTGRES_USER:-postgres}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-postgres}
TZ: ${TZ:-Asia/Shanghai}
ports:
- "${HOST_POSTGRES_PORT:-5432}:5432"
volumes:
- ./data/postgres:/var/lib/postgresql/data
restart: always
healthcheck:
test: ["CMD-SHELL", "pg_isready -U ${POSTGRES_USER:-postgres} -d ${POSTGRES_DB:-resume_genius}"]
interval: 60m
timeout: 5s
retries: 5
start_period: 30s
backend:
build:
context: ./backend
dockerfile: Dockerfile
args:
BUILDER_IMAGE: ${GO_BUILDER_IMAGE:-docker.1ms.run/golang:1.25-alpine}
RUNTIME_IMAGE: ${ALPINE_RUNTIME_IMAGE:-docker.1ms.run/alpine:3.19}
environment:
DB_HOST: postgres
DB_PORT: "5432"
DB_USER: ${POSTGRES_USER:-postgres}
DB_PASSWORD: ${POSTGRES_PASSWORD:-postgres}
DB_NAME: ${POSTGRES_DB:-resume_genius}
USE_MOCK: ${USE_MOCK:-false}
AI_API_URL: ${AI_API_URL:-}
AI_API_KEY: ${AI_API_KEY:-}
AI_MODEL: ${AI_MODEL:-default}
AI_HTTP_TIMEOUT_SECONDS: ${AI_HTTP_TIMEOUT_SECONDS:-180}
AGENT_MAX_ITERATIONS: ${AGENT_MAX_ITERATIONS:-10}
JWT_SECRET: ${JWT_SECRET:-}
JWT_TTL_HOURS: ${JWT_TTL_HOURS:-8760}
COOKIE_SECURE: ${COOKIE_SECURE:-false}
TZ: ${TZ:-Asia/Shanghai}
CHROME_BIN: "/usr/bin/chromium"
healthcheck:
test: ["CMD-SHELL", "curl -sf http://localhost:8080/health > /dev/null 2>&1 || exit 1"]
interval: 60m
timeout: 5s
retries: 3
start_period: 10s
ports:
- "${HOST_BACKEND_PORT:-8080}:8080"
volumes:
- ./data/uploads:/app/uploads
dns:
- 127.0.0.11
- 8.8.8.8
- 114.114.114.114
depends_on:
postgres:
condition: service_healthy
restart: always
workbench:
build:
context: ./frontend/workbench
dockerfile: Dockerfile
ports:
- "${HOST_WORKBENCH_PORT:-}:80"
depends_on:
backend:
condition: service_started
restart: always
marketing:
build:
context: ./frontend/marketing
dockerfile: Dockerfile
ports:
- "${HOST_MARKETING_PORT:-44321}:80"
depends_on:
workbench:
condition: service_started
backend:
condition: service_healthy
restart: always