All runtime configuration forDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/backtest-kit/backtest-kit-minio-s3-docker/llms.txt
Use this file to discover all available pages before exploring further.
backtest-kit-minio-s3-docker is driven by a single .env file located at the project root. The file is consumed in two ways: the Node.js process reads it directly when running on the host (via dotenv), and the main docker-compose.yaml passes it into the strategy runner container via the env_file directive. This means both deployment modes share an identical configuration surface — changing a value in .env affects the host run and the Docker run equally.
.env.example
.env.example
MinIO connection variables
Hostname or IP address of the MinIO S3 API. Use
localhost (or 127.0.0.1) when running backtest-kit directly on the host and MinIO is in a local container. Use host.docker.internal when backtest-kit itself runs inside a container (the main docker-compose.yaml maps this to the host gateway automatically). Can be set to any resolvable hostname or IP for a remote MinIO deployment.Port for the MinIO S3-compatible API. Matches the
9000 host port exposed in docker/minio/docker-compose.yaml. Only change this if you have remapped the MinIO port in your Compose file or are pointing at a remote endpoint on a non-standard port.MinIO access key (equivalent to an AWS
AWS_ACCESS_KEY_ID). Must match the MINIO_ROOT_USER value configured in docker/minio/docker-compose.yaml. All 16 persistence adapters authenticate with this credential when performing S3 GET, PUT, HEAD, and DELETE operations.MinIO secret key (equivalent to an AWS
AWS_SECRET_ACCESS_KEY). Must match MINIO_ROOT_PASSWORD in the MinIO Compose file. Treat this value with the same care as a database password.Redis connection variables
Hostname or IP address of the Redis instance that serves as the time-ordered index. The same
127.0.0.1 vs host.docker.internal distinction applies here as for CC_MINIO_ENDPOINT — use 127.0.0.1 for host-node runs and host.docker.internal for containerised runs.Redis port. Matches the
6379 host port exposed in docker/redis/docker-compose.yaml. Change only if you have remapped the port or are targeting a remote Redis instance on a non-standard port.Redis ACL username. The default Redis ACL creates a single
default user; leave this as default unless you have provisioned named Redis users via an aclfile or ACL SETUSER commands.Redis
requirepass authentication password. Must match the --requirepass argument set in docker/redis/docker-compose.yaml. Used by ioredis on every new connection.Container runtime variables
When backtest-kit runs inside thetripolskypetr/backtest-kit Docker image (via the main docker-compose.yaml), additional environment variables are passed through to configure the @backtest-kit/cli entrypoint. These are not read from .env — they are set inline as shell exports or in the environment: block of the Compose file.
Selects the execution mode. Must be one of:
backtest— replay historical candle datalive— connect to live exchange feedspaper— live feeds with simulated order execution
ENTRY=1 is set.Path to the compiled strategy bundle that the runner will
require(). The default ./build/index.cjs is the output of npm run build (Rollup). The project root is mounted as /workspace inside the container, so relative paths resolve correctly.Set to
1 to actually execute the runner. Without this flag the process starts but immediately exits, mirroring the --entry guard in the CLI mode. Prevents accidental execution when a container is restarted without the intent to run a strategy.Overrides the trading symbol (e.g.
BTCUSDT) defined in the strategy source. Useful for running the same compiled bundle against multiple symbols without a rebuild.Overrides the strategy name key registered in the strategy source.
Overrides the exchange identifier (e.g.
ccxt).Overrides the timeframe / frame name key (e.g.
Jan2026Frame).Set to
1 to enable the web UI served on port 60050. The container exposes this port, and the healthcheck polls it at http://localhost:60050/api/v1/health/health_check every 30 seconds.Set to
1 to enable Telegram trade notifications. Requires Telegram bot credentials to be configured in the strategy source.Set to
1 to enable verbose logging output. Useful for debugging adapter calls or tracking individual MinIO and Redis operations.Set to
1 to disable the in-process candle cache. Every candle read will hit MinIO directly. Primarily useful for testing cache-invalidation behaviour.Set to
1 to skip the flush-on-shutdown sequence. Normally backtest-kit writes any pending in-memory state to MinIO before exiting; this flag suppresses that behaviour.Production-like .env example
The following.env illustrates a setup pointing at dedicated MinIO and Redis hosts with non-default credentials, running the strategy runner in live mode:
.env (production example)
The
.env.example file ships with CC_MINIO_ENDPOINT=host.docker.internal and CC_REDIS_HOST=host.docker.internal — the correct values for containerised runs. If you run backtest-kit directly on the host with npm run start, replace them with loopback addresses: CC_MINIO_ENDPOINT=localhost (the code default in src/config/params.ts) and CC_REDIS_HOST=127.0.0.1 (also the code default). Both values differ from host.docker.internal because that hostname is only resolvable from within a Docker container; the host process must use the loopback address directly.