-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.env.example
More file actions
87 lines (75 loc) · 3.71 KB
/
Copy path.env.example
File metadata and controls
87 lines (75 loc) · 3.71 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
# Capital — environment configuration.
#
# Copy this file to `.env` (scripts/install.sh does it for you) and adjust the
# values. `.env` is gitignored — never commit real secrets. Docker Compose
# reads it for variable substitution and injects it into the engine container.
# --- PostgreSQL ----------------------------------------------------------
POSTGRES_USER=capital
POSTGRES_PASSWORD=capital
POSTGRES_DB=capital
POSTGRES_PORT=5432
# --- Engine --------------------------------------------------------------
CAPITAL_ENVIRONMENT=development
ENGINE_PORT=8000
# JWT signing secret — CHANGE THIS for any non-local deployment.
CAPITAL_JWT_SECRET=dev-insecure-jwt-secret-change-me-in-production
# Secret-encryption key — encrypts Binance/LLM API keys stored in the DB.
# CHANGE THIS, and back it up separately: without the exact key a database
# restore cannot decrypt the stored credentials.
CAPITAL_SECRET_KEY=dev-insecure-secret-key-change-me-in-production
# Seeded admin operator — created on first startup. Change the password
# after your first login.
CAPITAL_ADMIN_USERNAME=admin
CAPITAL_ADMIN_PASSWORD=changeme
# Directory scanned for custom code-strategy plugins (inside the engine).
CAPITAL_STRATEGY_PLUGINS_DIR=strategies/plugins
# --- Risk manager --------------------------------------------------------
# Global trading limits. Every limit is 0 (disabled) by default — uncomment
# and set a value to enable it.
#
# Max notional value of any single order (quote currency).
# CAPITAL_RISK_MAX_POSITION_NOTIONAL=1000
# Force-close a position when its unrealized loss/gain reaches this percent.
# CAPITAL_RISK_STOP_LOSS_PCT=5
# CAPITAL_RISK_TAKE_PROFIT_PCT=10
# Kill switch — halt new exposure past a daily realized loss / equity drawdown.
# CAPITAL_RISK_DAILY_LOSS_LIMIT=500
# CAPITAL_RISK_MAX_DRAWDOWN_PCT=20
# --- Logging, retention & notifications ----------------------------------
CAPITAL_LOG_LEVEL=INFO
# Days of history kept before the daily prune; 0 disables pruning.
CAPITAL_RETENTION_CANDLE_DAYS=90
CAPITAL_RETENTION_EQUITY_DAYS=90
# Telegram alerts (trades, errors, watchdog). Both must be set to enable.
# CAPITAL_TELEGRAM_BOT_TOKEN=
# CAPITAL_TELEGRAM_CHAT_ID=
# --- AI / LLM ------------------------------------------------------------
# Provider for AI strategies: claude | openai | codex | deepseek | ollama | gemini
CAPITAL_AI_PROVIDER=claude
# CAPITAL_AI_MODEL= # blank uses the adapter's default model
# CAPITAL_AI_API_KEY=
# CAPITAL_AI_BASE_URL= # OpenAI-compatible endpoint (Codex/DeepSeek/Ollama)
# --- MCP server ----------------------------------------------------------
# `python mcp_server.py` exposes the API as agent tools. It calls the API
# at CAPITAL_API_URL authenticated with an API token created in Settings.
# CAPITAL_API_URL=http://localhost:8000
# CAPITAL_MCP_TOKEN=
# --- Web -----------------------------------------------------------------
WEB_PORT=5173
# --- Production deployment -----------------------------------------------
# Used by docker-compose.prod.yml + Caddy (see scripts/deploy.sh and
# docs/deployment.md).
#
# Hostname Caddy serves the dashboard on — a Tailscale MagicDNS name for a
# private deploy, or a real domain for a public cloud VM.
CAPITAL_HOSTNAME=localhost
# Interface Caddy binds 80/443 to:
# 127.0.0.1 — local only (the safe default)
# <tailscale-ip> — reachable only over your tailnet
# 0.0.0.0 — public cloud VM (keep a host firewall in front)
TAILSCALE_HOST=127.0.0.1
# TLS mode:
# internal — Caddy's private CA (Tailscale / LAN; no public DNS)
# you@example.com — ACME email → a public Let's Encrypt certificate for
# CAPITAL_HOSTNAME (needs a real domain pointing here)
CAPITAL_TLS=internal