# Template for the bitcoin-staking e2e secrets. Copy to `.env` (gitignored) and # fill in. The test helpers SELF-LOAD this file (tests/helpers/utils.ts, anchored # to the package dir, real env vars win) — no `set -a; . ./.env` needed: # cd packages/bitcoin-staking # jest must run from the package dir # RECORD=1 npx jest tests/regtest/actions/ --runInBand # Replay/offline runs do NOT need this — the suites fall back to the public # bond-admin address (ST1V2ASRWG…); the key is only used to SIGN live txs. # pox_5_bond_admin private key (hex, 33-byte compressed → 66 chars incl. the # trailing "01"). Shared secret controlling the bond-admin role on the local # regtest env AND the hosted private testnet — keep it OUT of git. # Derive it from the bond-admin seed phrase with @stacks/wallet-sdk: # const w = await generateWallet({ secretKey: SEED, password: '' }); # w.accounts[0].stxPrivateKey // → BOND_ADMIN_KEY (address ST1V2ASRWG…) BOND_ADMIN_KEY= # Network lifecycle commands (inversion of control). The harness never runs # docker itself — `networkUp`/`networkDown`/`networkReset` exec exactly these # (`networkReset` = WIPE_CMD then UP_CMD). # Leave unset for remote/externally-managed nets (every op no-ops). The local # stacks-regtest-env commands: # # NOTE: do NOT scale tx-broadcaster to 0 — its steady tx stream keeps Nakamoto # block production and the signer state machines live (without it the chain # stalls at the first quiet tenure). It floods from DEDICATED keys # (ST5B3TD…, ST2TBKDC…), so account1/2/3 nonces/balances stay clean for tests. NETWORK_UP_CMD='cd ../../../stacks-regtest-env && docker compose up -d --build' NETWORK_DOWN_CMD='cd ../../../stacks-regtest-env && docker compose down' NETWORK_RESET_CMD='cd ../../../stacks-regtest-env && docker compose down --volumes --remove-orphans --timeout=1 && docker compose up -d --build'