🚀 How to Solo Mine Bitcoin with Bitaxe Touch, Bitcoin Knots, and own Stratum pool

A full guide to building a sovereign solo mining setup with Bitaxe, Bitcoin Knots, and own Stratum pool — using open-source tools, your own node, and full control of block templates.

nobody

7. Juli 2025July 7, 2025 · 8 Min. Lesezeit8 min read · Aktualisiert am 9. Februar 2026Updated February 9, 2026

Interested in running your own solo mining setup with full node sovereignty? Here's a complete, battle-tested guide to setting up a Bitaxe Touch single-chip miner (BM1370) with Bitcoin Knots and the public-pool GBT-to-Stratum bridge.

🛠️ Hardware Overview#

🧰 Setup & Installation#

1. Prepare Your NUC#

2. Install Required Software#

You’ll be installing:


📝 Explanation:

Your Bitaxe Touch miner connects to your own public-pool, which acts as a GBT-to-Stratum bridge. While Bitaxe speaks Stratum, it’s ultimately mining on block templates generated by your own Bitcoin Knots node via the getblocktemplate (GBT) RPC.

In other words, public-pool translates GBT-based templates from your node into Stratum-compatible work for the miner—enabling full block template control without modifying Bitaxe itself.

This setup preserves mining self-sovereignty: block construction is handled entirely by your own Bitcoin node, not a third-party pool. You're validating transactions independently and maintaining full control over what gets mined.


🖧 Networking considerations:


⚙️ Configuring Bitcoin Knots#

Option A: Download Binary#

wget "https://github.com/bitcoinknots/bitcoin/releases/download/v28.1.knots20250305/bitcoin-28.1.knots20250305-x86_64-linux-gnu.tar.gz"

Option B: Build from Source#

sudo apt install -y build-essential autoconf pkg-config libtool libboost-all-dev
source ~/.bashrc
git clone -b v28.1.knots20250305 https://github.com/bitcoinknots/bitcoin.git
cd bitcoin
./autogen.sh
./configure --without-gui
make -j$(nproc)
mkdir ~/bin
source ~/.profile
for i in bitcoind bitcoin-cli bitcoin-tx bitcoin-util; do strip -o ~/bin/$i src/$i; done


Create a file ~/.bitcoin/bitcoin.conf with the followings contents:

# bitcoin.conf – spam-filtering and mempool policy for Bitcoin Knots
# See more options and their defaults with: bitcoind -help-debug
# Last updated: July 6th, 2025

txindex=1  # Maintain a full transaction index for getrawtransaction RPC

# DEFAULTS for Bitcoin Knots v28.1.knots20250305
## Transaction relay and spam filtering
permitbarepubkey=0         # Disallow bare pay-to-pubkey outputs (P2PK)
permitbaremultisig=0       # Disallow bare multisig outputs (non-P2SH)
maxscriptsize=1650         # Reject scripts larger than this many bytes
datacarriersize=42         # Reject OP_RETURN data larger than this many bytes
datacarriercost=1          # Virtual size multiplier for OP_RETURN data
rejectparasites=1          # Reject parasitic overlay protocols
minrelaytxfee=0.00001      # Minimum fee rate (BTC/kvB) to relay transactions
bytespersigopstrict=20     # Enforce minimum bytes per sigop (strict)
bytespersigop=20           # Target bytes per sigop (soft limit)
dustrelayfee=0.00003       # Treat outputs below this fee rate as uneconomical dust
## Mempool ancestor/descendant limits
limitancestorcount=25      # Reject txs with ≥ this many unconfirmed ancestors
limitancestorsize=101      # Reject if ancestor chain exceeds this size (KB)
limitdescendantcount=25    # Reject txs creating ≥ this many descendants
limitdescendantsize=101    # Reject if descendant chain would exceed this size (KB)
## Other
#listen=1                   # Default, but ensures the node accepts inbound connections
#discover=1                 # Automatically detects your IP
#dnsseed=1                  # Use DNS to find peers

# Custom
## Transaction relay and spam filtering
rejecttokens=1             # Reject transactions using non-Bitcoin tokens
onlynet=ipv4               # Optional: restrict to IPv4 if you don’t want IPv6 traffic (Valid options: ipv4, ipv6, onion, i2p, cjdns)

## Based on https://github.com/OCEAN-xyz/datum_gateway/blob/master/README.md (July 6th 2025)
blockmaxsize=3985000
blockmaxweight=3985000
#blocknotify=killall -USR1 datum_gateway
maxmempool=1000
blockreconstructionextratxn=1000000

# Solo Mining
server=1                   # Enables RPC server
rpcuser=user               # Make sure to update BITCOIN_RPC_USER in public-pool/.env (you'll see it later following the instructions)
rpcpassword=s0mePassword   # Make sure to update BITCOIN_RPC_PASSWORD in public-pool/.env (you'll see it later following the instructions)
rpcallowip=192.168.8.0/24  # Allow your Miner or local network to access the node
rpcallowip=172.16.0.0/12   # For Docker: https://github.com/benjamin-wilson/public-pool.git
rpcbind=0.0.0.0            # Listen on all interfaces (or limit to LAN)

Run Bitcoin Knots:#

bitcoind

Wait for full sync. It can take a day or two before it syncs with the tip of the chain (it downloads about 780GiB of data), can be referred to as IBD (Initial Block Download).

Once started and fully synced, you should expect initialblockdownload set to false, e.g.:

$ bitcoin-cli getblockchaininfo | grep initialblockdownload
  "initialblockdownload": false,


Hint: you can get the time of the current block using this command

bitcoin-cli getblockchaininfo | jq -r .bestblockhash | xargs -I'{}' bitcoin-cli getblock {} | jq -r .time | xargs -I'{}' date -d @{}

🐳 Install Docker + Docker Compose#

Follow the official Docker docs: 👉 <https://docs.docker.com/engine/install/ubuntu/>

Use the "Install using the apt repository" method, where you will set up Docker's apt repository, install the Docker packages and test docker installed correctly by running the hello-world image.

You can add your user to the docker group, so you can use docker / docker compose commands without "sudo". To do so, run:

> NOTE: change "user" with your username in Ubuntu

sudo usermod -aG docker user

And re-login into your user session for it to pick up its new group. (Or just run newgrp docker for session-based switch)


🔌 Set Up public-pool (Stratum Server)#

git clone https://github.com/benjamin-wilson/public-pool.git
cd public-pool

docker-compose.yml#

services:
  public-pool:
    container_name: public-pool
    build:
      context: .
      dockerfile: Dockerfile
    restart: unless-stopped
    extra_hosts:
      - "host.docker.internal:host-gateway"
    ports:
      - "${STRATUM_PORT}:${STRATUM_PORT}/tcp"
      - "${API_PORT}:${API_PORT}/tcp"
    volumes:
      - "./${NETWORK}-DB:/public-pool/DB"
      - "./.env:/public-pool/.env:ro"
    environment:
      - NODE_ENV=production

Create the .env file with the following contents:

> NOTE: it is based on the .env.example file.

#bitcoin node running in your private network 192.168.8.0/24
#BITCOIN_RPC_URL=http://192.168.8.227

# 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=user
BITCOIN_RPC_PASSWORD=s0mePassword
BITCOIN_RPC_PORT=8332
BITCOIN_RPC_TIMEOUT=10000

# You can use this instead of BITCOIN_RPC_USER and BITCOIN_RPC_PASSWORD
#BITCOIN_RPC_COOKIEFILE=

# Enable in bitcoin.conf with
# zmqpubrawblock=tcp://*:3000
# BITCOIN_ZMQ_HOST="tcp://192.168.8.227:3000"

API_PORT=3334
STRATUM_PORT=3333

#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
# Default is "Public-Pool", you can change it to any string it will be removed if it will make the block or coinbase script too big
POOL_IDENTIFIER="Public-Pool"

Then build and run:

docker compose build
docker compose up -d

📊 Web UI for public-pool (optional)#

git clone https://github.com/benjamin-wilson/public-pool-ui.git
cd public-pool-ui

Edit src/environments/environment.prod.ts:#

> NOTE: make sure to set your NUC's IP instead of 192.168.8.227; and set http instead of https.

export const environment = {
    production: true,
    API_URL: 'http://192.168.8.227:3334',
    STRATUM_URL: '192.168.8.227:3333'
};

Build and run:

docker build -t public-pool-ui .
docker run --name public-pool-ui -e STRATUM_URL=192.168.8.227:3333 -d --restart=unless-stopped -p 8080:80 public-pool-ui

Browse to: 👉 http://192.168.8.227:8080


🔧 Configure Bitaxe Touch#

Access your Bitaxe miner at http://192.168.8.203/pools

Main Pool:#

Fallback Pool (e.g. solo.ckpool.org):#

Configure as a backup in case your local node is down.

Click Save & Restart Device.


✅ Verifying It's Working#

tail -f ~/.bitcoin/debug.log

Example output:

CreateNewBlock(): total size: 488198 block weight: 1561676 txs: 568 fees: 815375 sigops 2312
docker compose logs -f public-pool

Look for:

New client ID: ::ffff:192.168.8.203
getblocktemplate tx count: 692
block height change

🧠 Final Thoughts#

With this setup:

This is as sovereign as Bitcoin mining gets.

🛠️ Bonus Tips:#

Create /etc/systemd/system/bitcoind.service file with the following contents:

[Unit]
Description=Bitcoin daemon
After=network.target

[Service]
ExecStart=/home/user/bin/bitcoind
ExecStop=/home/user/bin/bitcoin-cli stop
User=user
Group=user
Restart=always
PrivateTmp=true
TimeoutStopSec=60s
TimeoutStartSec=10s
StartLimitInterval=120s
StartLimitBurst=5

[Install]
WantedBy=multi-user.target
pkill bitcoind
sleep 10s
pkill tor
systemctl daemon-reload
systemctl enable bitcoind.service
systemctl start bitcoind.service
#BITCOIN_RPC_COOKIEFILE=#BITCOIN_RPC_URL=http#DISCORD_BOT_CHANNEL_ID=#DISCORD_BOT_CLIENTID=#DISCORD_BOT_GUILD_ID=#TELEGRAM_BOT_TOKEN=#bitaxe#bitcoin#blocknotify=killall#discover=1#dnsseed=1#listen=1#mining#nuc#optional

Written by

Comments

No comments yet. Start the conversation.

Contents

9 sections

  1. 🛠️ Hardware Overview
  2. 🧰 Setup & Installation
  3. ⚙️ Configuring Bitcoin Knots
  4. 🐳 Install Docker + Docker Compose
  5. 🔌 Set Up public-pool (Stratum Server)
  6. 📊 Web UI for public-pool (optional)
  7. 🔧 Configure Bitaxe Touch
  8. ✅ Verifying It's Working
  9. 🧠 Final Thoughts