-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
33 lines (33 loc) · 1.4 KB
/
docker-compose.yml
File metadata and controls
33 lines (33 loc) · 1.4 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
services:
proxy:
build: .
restart: unless-stopped
# network_mode: host gives direct LAN access (Linux only).
# On Mac/Docker Desktop, comment out network_mode and uncomment ports below.
# Use host.docker.internal instead of LAN IPs for draft/target URLs on Mac.
network_mode: host
# ports:
# - "8088:8088"
environment:
TIGHTWAD_DRAFT_URL: "http://192.168.1.10:11434"
TIGHTWAD_DRAFT_MODEL: "qwen3:8b"
TIGHTWAD_DRAFT_BACKEND: "ollama"
TIGHTWAD_TARGET_URL: "http://192.168.1.20:11434"
TIGHTWAD_TARGET_MODEL: "qwen3:32b"
TIGHTWAD_TARGET_BACKEND: "ollama"
TIGHTWAD_PORT: "8088"
TIGHTWAD_MAX_DRAFT_TOKENS: "32"
# REQUIRED when binding to a non-loopback host (host network mode or
# external port mapping). Generate with:
# python3 -c "import secrets; print(secrets.token_urlsafe(32))"
# To run unauthenticated anyway (NOT recommended), set
# TIGHTWAD_ALLOW_UNAUTHENTICATED=true and remove this var.
TIGHTWAD_PROXY_TOKEN: "${TIGHTWAD_PROXY_TOKEN:?set TIGHTWAD_PROXY_TOKEN in your env or .env file}"
volumes:
- ./logs:/root/.tightwad/logs # persist proxy logs across restarts
healthcheck:
test: ["CMD", "python", "-c", "import httpx; httpx.get('http://127.0.0.1:8088/v1/models', timeout=5).raise_for_status()"]
interval: 10s
timeout: 5s
retries: 5
start_period: 5s