THAMER
Sovereign Bitcoin Wallet

WALLET AI BITCOIN

Your Bitcoin Wallet. Your Keys. Your Engine.

Self-hosted Bitcoin software built for developers, applications, and AI agents.

CREATE WALLET

Rebuilding the Engine Binary or Docker Image Without Deleting Volumes

permalink THAMER
#bitcoin-core#linux#server-administration#wab-engine

Purpose and deployment assumptions

A build changes code artifacts; a restart changes process state. Back up configuration and capture the image digest or binary checksum first.

The configuration example supplied for this documentation is /etc/btc/bitcoin.conf, with one mainnet and one testnet3 process. The actual startup scripts, container service names, loaded config path and data mounts have not been independently inspected. Commands below are conditional examples, not an instruction to replace a proven deployment topology.

Inspect before changing anything

Run read-only inspection first. In a known Docker Compose project, docker compose ps and docker compose config --services show service names. For a known systemd unit, systemctl status UNIT identifies status. On a host, ps -ef | grep '[b]itcoind' helps locate running processes, but may not show container internals. Confirm the configuration actually loaded and which chain each process serves.

A sample read-only check, from the correct authenticated RPC environment, is bitcoin-cli -chain=main getblockchaininfo; testnet3 commonly uses bitcoin-cli -chain=test getblockchaininfo. Exact flags, credentials and container access vary. Do not expose RPC credentials in terminal history or published documentation.

Procedure

Build a candidate separately; preserve the existing Compose file, data mounts, signed wallet laws and Core settings; deploy only after tests; keep a rollback artifact.

  1. Record current health, running services, chain identities, block heights, configuration checksum, free disk space and volume mounts.
  1. Make a timestamped backup of the actual loaded configuration; retain a rollback binary or image if rebuilding.
  1. Apply only the intended change in a maintenance window. Choose the existing service manager and actual service name; do not invent commands for unknown deployments.
  1. Recheck process health, RPC, chain synchronization, engine readiness and read-only wallet results.
  1. If checks fail, restore the previous configuration or artifact, restart via the same manager, and repeat verification.

Common failure modes

Using docker compose down -v; changing mount paths; running schema migrations without rollback.

Safe operations for AI agents

Agents may collect read-only diagnostics, but production restart, rebuild, config edits, data moves and wallet sends should require explicit operator approval. Never delete volumes or blockchain data as an automatic repair. Never log BTC KEY, BTC SECRET or other wallet secrets.

Related ASK

What is the difference between restarting and rebuilding the Bitcoin engine?

https://thamer.org/ask/bitcoin-engine-ops-rebuild-engine

Does docker compose down delete Bitcoin Core data?

https://thamer.org/ask/bitcoin-engine-ops-compose-down

Questions & Answers

Explore all questions →

Latest from the Lab

THAMER illustrated developer portrait and signature

ABOUT THE DEVELOPER

Independent Software Developer specializing in Bitcoin Script, Golang, and AI Agents.

Software engineering · Independent research · Open-source projects