-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.dev.yml
More file actions
45 lines (44 loc) · 1.2 KB
/
docker-compose.dev.yml
File metadata and controls
45 lines (44 loc) · 1.2 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
version: '3.8'
services:
vite:
build:
context: .
dockerfile: Dockerfile.dev
volumes:
- .:/app
- /app/node_modules # Use container's node_modules
- /app/dist # Use container's dist directory
ports:
- "5173:5173" # Vite dev server
- "24678:24678" # Vite HMR
environment:
- NODE_ENV=development
- VITE_HOST=0.0.0.0
- VITE_PORT=5173
- NEXT_PUBLIC_SUPABASE_URL=${NEXT_PUBLIC_SUPABASE_URL}
- NEXT_PUBLIC_SUPABASE_ANON_KEY=${NEXT_PUBLIC_SUPABASE_ANON_KEY}
network_mode: "host" # Use host networking to work with Tailscale
healthcheck:
test: ["CMD-SHELL", "curl -f http://localhost:5173 || exit 1"]
interval: 30s
timeout: 10s
retries: 3
start_period: 40s
restart: unless-stopped
logging:
driver: "json-file"
options:
max-size: "10m"
max-file: "3"
deploy:
resources:
limits:
cpus: '1'
memory: 2G
reservations:
cpus: '0.25'
memory: 512M
labels:
- "com.localsource.description=Vite Development Server"
- "com.localsource.service=frontend"
- "com.localsource.environment=development"