Repository navigation
Expand file tree
/
Copy path.env.example
More file actions
81 lines (74 loc) · 3.32 KB
/
Copy path.env.example
File metadata and controls
81 lines (74 loc) · 3.32 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
# Copy this file to .env before running docker compose.
API_KEY=change-me
# Multi-key auth (A): comma-separated; any entry passes. Empty = no auth.
# Canonical list name first, legacy alias second (both merge, empty never blocks).
# OPENCODE_API_KEYS=key-alpha,key-beta
# API_KEYS=key-alpha,key-beta,key-gamma
OPENCODE_SERVER_PASSWORD=change-me-too
# Safer default. Keep true unless you really want model tool access.
DISABLE_TOOLS=true
# External tool bridge is implemented by the proxy, not by OpenCode internal tools.
# Supported values today:
# - OPENCODE_EXTERNAL_TOOLS_MODE=proxy-bridge
# - OPENCODE_EXTERNAL_TOOLS_CONFLICT_POLICY=namespace
OPENCODE_EXTERNAL_TOOLS_MODE=proxy-bridge
OPENCODE_EXTERNAL_TOOLS_CONFLICT_POLICY=namespace
# External tool policy (canonical OPENCODE_EXTERNAL_TOOL_* > legacy raw alias >
# config.json short key > default; invalid values fall through to the next).
# OPENCODE_EXTERNAL_TOOL_POLICY_MODE=enforce
# OPENCODE_EXTERNAL_TOOL_DEFAULT_RISK_LEVEL=low
# OPENCODE_EXTERNAL_TOOL_ALLOWLIST=
# OPENCODE_EXTERNAL_TOOL_DENYLIST=
# OPENCODE_EXTERNAL_TOOL_REQUIRE_CONFIRMATION_FOR=
# EXTERNAL_TOOL_POLICY_MODE=enforce
# EXTERNAL_TOOL_DEFAULT_RISK_LEVEL=low
# EXTERNAL_TOOL_ALLOWLIST=
# EXTERNAL_TOOL_DENYLIST=
# EXTERNAL_TOOL_REQUIRE_CONFIRMATION_FOR=
# Helpful when running behind OpenClaw or other clients that already manage prompts.
OPENCODE_PROXY_PROMPT_MODE=plugin-inject
OPENCODE_PROXY_OMIT_SYSTEM_PROMPT=true
# Periodically clean proxy-owned conversation/session storage.
OPENCODE_PROXY_AUTO_CLEANUP_CONVERSATIONS=true
OPENCODE_PROXY_CLEANUP_INTERVAL_MS=43200000
OPENCODE_PROXY_CLEANUP_MAX_AGE_MS=86400000
# Optional overrides
# Leave an entry empty to fall through to config.json / the built-in default.
# OPENCODE_PROXY_PORT=10000
# PORT=10000
# OPENCODE_SERVER_PORT=10001
# OPENCODE_SERVER_URL=http://127.0.0.1:10001
# BIND_HOST=0.0.0.0
# OPENCODE_PROXY_BIND_HOST=0.0.0.0
# Canonical tool switch (legacy DISABLE_TOOLS also read; canonical wins)
# OPENCODE_DISABLE_TOOLS=true
# OPENCODE_USE_ISOLATED_HOME=false
# OPENCODE_PROXY_REQUEST_TIMEOUT_MS=180000
# Retry budget after the initial attempt (0-5, default 3; total attempts = 1+n)
# OPENCODE_PROXY_RETRY_MAX_RETRIES=3
# RETRY_MAX_RETRIES=3
# OPENCODE_PROXY_DEBUG=false
# OPENCODE_PATH=opencode
# OPENCODE_ZEN_API_KEY=
# Internal allowlist (only applies when a request carries no tools)
# OPENCODE_INTERNAL_WEB_FETCH_ENABLED=false
# OPENCODE_INTERNAL_ALLOWED_TOOLS=
# OPENCODE_INTERNAL_TOOL_METRICS_ENABLED=true
# OPENCODE_TOOL_DISCOVERY_FIXTURE=
# Fallback proxy pool (P3): direct-only until a free-limit 429 engages it.
# Socks5 first-class; loopback targets always bypass.
# OPENCODE_UPSTREAM_PROXIES=socks5://user:pass@10.0.0.1:1080,http://user:pass@10.0.0.2:8080
# UPSTREAM_PROXIES=socks5://user:pass@10.0.0.1:1080,http://user:pass@10.0.0.2:8080
# OPENCODE_UPSTREAM_PROXY_STRATEGY=failover-rr
# UPSTREAM_PROXY_STRATEGY=failover-rr
# OPENCODE_UPSTREAM_PROXY_COOLDOWN_MS=300000
# UPSTREAM_PROXY_COOLDOWN_MS=300000
# OPENCODE_UPSTREAM_PROXY_NO_PROXY=localhost,127.0.0.1,::1
# UPSTREAM_PROXY_NO_PROXY=localhost,127.0.0.1,::1
# Diagnostics
# OPENCODE_HEALTH_DETAILS_ENABLED=true
# OPENCODE_HEALTH_DETAILS_REQUIRE_AUTH=true
# OPENCODE_METRICS_ENABLED=false
# OPENCODE_METRICS_REQUIRE_AUTH=true
# Backend management (default false; Docker entrypoint owns the backend)
# OPENCODE_PROXY_MANAGE_BACKEND=false