# bitcoin node running in your private network 192.168.1.0/24 BITCOIN_RPC_URL=http://192.168.1.100 # bitcoin node running undockered on the same PC # needs to add rpcallowip=172.16.0.0/12 to your bitcoin.conf #BITCOIN_RPC_URL=http://host.docker.internal BITCOIN_RPC_USER= BITCOIN_RPC_PASSWORD= BITCOIN_RPC_PORT=8332 BITCOIN_RPC_TIMEOUT=10000 # Keep an authoritative getblocktemplate longpoll outstanding so new-tip work # does not wait for the ZMQ -> RPC round trip. The normal ZMQ feed remains a watchdog. BLOCK_TEMPLATE_LONGPOLL_TIMEOUT_MS=600000 BLOCK_TEMPLATE_RETRY_INITIAL_MS=25 BLOCK_TEMPLATE_RETRY_MAX_MS=1000 # Optional comma-separated Bitcoin Core RPC endpoints. Each keeps an independent # GBT longpoll open, but its template is published only when the primary Core's # best block hash exactly authorizes the same tip. Endpoints currently share the # primary RPC credentials/port. #BITCOIN_RPC_AUX_URLS=http://bitcoin-core-2,http://bitcoin-core-3 # Enable in bitcoin.conf with: # zmqpubhashblock=tcp://0.0.0.0:3000 BITCOIN_ZMQ_TOPIC=hashblock BITCOIN_ZMQ_HOST=tcp://192.168.1.100:3000 API_PORT=3334 # Docker host/IP and public host port for the API listener. # Keep API_BIND_HOST as 127.0.0.1 when a reverse proxy terminates public traffic. API_BIND_HOST=127.0.0.1 API_PUBLIC_PORT=3334 API_WORKERS=4 # Docker json-file log rotation. Applies when using the compose files. DOCKER_LOG_MAX_SIZE=100m DOCKER_LOG_MAX_FILES=5 # Keep high-volume production logging off by default. Enable only during a # focused diagnostic window. STRATUM_FANOUT_LOG_ENABLED=false BLOCK_NOTIFICATION_TRACE_LOG_ENABLED=false DATUM_VERBOSE_LOGGING=false SV2_AUTH_FAILURE_LOG_ENABLED=false # Plain TCP Stratum ports accept both SV1 JSON-RPC and SV2 Noise/binary traffic. # Legacy/default ports mine in solo mode. STRATUM_PORTS=3333,3332,3331,3330 # Optional PPLNS-mode SV1/SV2 autodetect ports. #PPLNS_STRATUM_PORTS= # `auto` assigns available CPUs after reserving API_WORKERS plus one master CPU. # For fixed topology, set an explicit positive integer. STRATUM_WORKERS=auto STRATUM_WORKER_MAX_MEMORY_RESTART=4096M # High-byte base for pool-assigned SV2 extranonce prefixes. PM2 reserves two # values per NODE_APP_INSTANCE so an old/new reload pair cannot overlap. Keep # base + (2 * worker index) + reload parity <= 255. Separate pool containers # sharing work must use non-overlapping ranges of 2 * STRATUM_WORKERS values. SV2_EXTRANONCE_NAMESPACE_BASE=0 STRATUM_MIN_DIFFICULTY=1 STRATUM_SOCKET_TIMEOUT_MS=3600000 STRATUM_TCP_KEEPALIVE_INITIAL_DELAY_MS=60000 # Disconnect slow/non-reading SV1 clients before their per-socket write queue # can grow without bound. Includes bytes already buffered by Node.js. STRATUM_MAX_SOCKET_BUFFER_BYTES=262144 # Immediately publish a consensus-valid, subsidy-only solo job before the full # transaction template. SV2 uses the same activation to select its pre-staged # future job; the full job then follows on the active tip. SV1_SUBSIDY_BRIDGE_ENABLED=true # Publish only authoritative fixed-width GBT fields on the first Redis command. # Workers promote their already-built next-height coinbase/notify buffers. SV1_COMPACT_PRESTAGE_ACTIVATION_ENABLED=true # Rolling-deploy aid for old workers. Leave false after workers understand the # compact activation protocol; true publishes the larger empty bridge afterward. SV1_COMPACT_ACTIVATION_COMPATIBILITY_BRIDGE=false # Comma-separated: solo,pplns. PPLNS requires a fresh precomputed snapshot; # solo remains the safe default and is always published first when both are set. SV1_SUBSIDY_BRIDGE_PAYOUT_MODES=solo # Give the dedicated urgent Redis socket a short opportunity to acknowledge the # empty bridge before full-template hashing/serialization begins. On timeout the # master retries immediately through the independent normal command socket. SV1_BRIDGE_PUBLISH_BUDGET_MS=10 # Build next-height per-miner coinbases in background batches and yield between # batches so normal share processing remains responsive. SV1_PRESTAGE_BATCH_SIZE=500 # Operational target only: fanout logs flag workers above this client count so # STRATUM_WORKERS can be raised before one event loop becomes the bottleneck. STRATUM_FANOUT_TARGET_CLIENTS_PER_WORKER=10000 SV1_SUBSIDY_BRIDGE_PPLNS_SEED_MAX_AGE_MS=300000 STRATUM_JOB_RETENTION_MS=300000 STRATUM_SUBMISSION_DEDUP_TTL_MS=300000 STRATUM_SUBMISSION_DEDUP_MAX_ENTRIES=10000 # Optional additional SV2-only mining ports. Usually unnecessary when STRATUM_PORTS are exposed. #STRATUM_V2_PORTS= #PPLNS_STRATUM_V2_PORTS= #SV2_START_DIFFICULTY=100000 #SV2_TARGET_SHARES_PER_MINUTE=2 #SV2_DIFFICULTY_CHECK_INTERVAL_MS=60000 #STRATUM_V2_SOCKET_TIMEOUT_MS=3600000 # Per-client lifecycle bounds. Obsolete queued jobs are coalesced; clients are # disconnected instead of dropping still-recoverable candidates or buffering forever. SV2_JOB_RETENTION_MS=300000 SV2_MAX_RETAINED_JOBS_PER_CHANNEL=64 SV2_MAX_QUEUED_JOB_OPERATIONS=4 SV2_MAX_SOCKET_BUFFER_BYTES=262144 SV2_SOCKET_WRITE_TIMEOUT_MS=2000 #SV2_AUTHORITY_PRIVKEY= #SV2_JDP_PORTS= #PPLNS_SV2_JDP_PORTS= #SV2_JDP_POOL_PAYOUT_ADDRESS= #SV2_JDP_TOKEN_TTL_MS=600000 #SV2_TDP_PORTS= #PPLNS_SV2_TDP_PORTS= #SV2_TDP_POOL_PAYOUT_ADDRESS= # Optional DATUM Prime-compatible listener. DATUM_POOL_PAYOUT_ADDRESS is the # required pool coinbase output DATUM gateways must include in custom templates. #DATUM_PORTS= #PPLNS_DATUM_PORTS= #DATUM_POOL_PAYOUT_ADDRESS= #DATUM_SHARE_DIFFICULTY=1 # 32-byte hex seed for the DATUM server identity key. DATUM clients must be # configured with the matching logged public key. #DATUM_IDENTITY_SEED= STRATUM_SECURE=true SECURE_STRATUM_PORTS=4333,4332,4331,4330 #PPLNS_SECURE_STRATUM_PORTS= STRATUM_MAX_CONNECTIONS_PER_LISTENER=10000 STRATUM_TLS_HANDSHAKE_TIMEOUT_MS=10000 #optional telegram bot #TELEGRAM_BOT_TOKEN= #optional discord bot #DISCORD_BOT_CLIENTID= #DISCORD_BOT_GUILD_ID= #DISCORD_BOT_CHANNEL_ID= #optional DEV_FEE_ADDRESS= # mainnet | testnet NETWORK=mainnet API_SECURE=false #postgresql DB_HOST=timescaledb DB_PORT=5432 DB_USERNAME=public_pool DB_PASSWORD=public_pool DB_DATABASE=public_pool DB_POOL_SIZE=10 DB_SSL=false DB_SSL_REJECT_UNAUTHORIZED=true #accepted share accounting SHARE_ACCOUNTING_BATCH_SIZE=500 SHARE_ACCOUNTING_FLUSH_INTERVAL_MS=25 SHARE_ACCOUNTING_MAX_QUEUE_SIZE=50000 SHARE_ACCOUNTING_SUMMARY_CACHE_MS=2500 SHARE_ACCOUNTING_SUMMARY_CACHE_MAX=10000 CLIENT_HASHRATE_PERSIST_INTERVAL_MS=60000 SHARE_ROLLUP_ENABLED=true SHARE_ROLLUP_INTERVAL_MS=60000 SHARE_ROLLUP_SAFETY_LAG_SECONDS=30 SHARE_ROLLUP_MAX_SHARES_PER_BATCH=5000000 # payout snapshot accounting PAYOUT_SNAPSHOT_ENABLED=true PAYOUT_METHOD=pplns PAYOUT_WINDOW_FACTOR=4 PAYOUT_BOOTSTRAP_WINDOW=true # solo preserves current one-address coinbase payouts. Set to snapshot to pay # the latest payout snapshot directly in coinbase outputs. PAYOUT_COINBASE_MODE=solo PAYOUT_MAX_COINBASE_OUTPUTS=200 PAYOUT_MIN_OUTPUT_SATS=546 PAYOUT_FEE_ADDRESS= PAYOUT_FEE_PERCENT=0 PAYOUT_COINBASE_WEIGHT_BUDGET=26000 #redis REDIS_URL=redis://redis:6379 PRODUCTION=false