Automated P2Pool Deployment

We are currently working on P2Pool Anywhere a project for automated deployment to (bare-metal) severs, VMs, and systemd containers.

This installation is working on an internal network and will be publicly released and fully documented soon.

Currently testing on Pi 5

Although we intend to extend this installation to other x86_64 and aarch64-based systems, our initial focus is on the Raspberry Pi 5 and Raspberry Pi Compute Module 5. One reason for this choice is the 256 Foundation's Libre Board (Open-source Bitcoin miner control board) is nearly identical to the Raspberry Pi Compute Module 5 IO Board.

Configuration Notes

The current configuration is optimized for software development and testing and runs the P2Poolv2 Stack in a guest NixOS VM on a NixOS host. This results in a few extra installation steps but allows for faster rebuilds and running multiple P2Poolv2 Stack instances on the same device. We use [extra-container] to separate the guest and host configurations.

Tested Hardware

We have been testing a Raspberry Pi Development Kit for Compute Module 5 which includes a CM5 with 4 GB RAM. Although CM5s can be hard to find, the Development Kit seems to be in-stock at many distributors.

Preview Instructions

Get the P2Poolv2 Deployment Flake and set your configuration

  1. git clone <TBD>

  2. cd <dir>

  3. vi local.config

You’ll need to set your hostname, network information, SSH keys, etc.

Format the NVMe and install NixOS

  1. Write the installer SD card image from nvmd/nixos-raspberrypi to a USB stick and boot the Pi 5 with it.

  2. Format the NVMe and Install NixOS

  3. nix develop

  4. nixos-anywhere --flake .#<hostname> root@<address>

    NOTE

    Using nixos-anywhere and Disko will wipe the NVMe drive, so should only be used for an initial installation.

Deploy the P2Poolv2 container

  1. Build the container closure

    1. nix build .#packages.default.aarch64-linux

    2. Note that the package path is reversed (it should be aarch64-linux.default, TBD)

  2. Copy the configuration + updated binaries to the Pi

    1. nix copy --to ssh://nixos@<address> ./result

  3. Build/rebuild the container

    1. ssh -t nixos@<address> "$(readlink ./result)/bin/container" create --update-changed

      NOTE

      These commands can easily be combined into a simple shell script.

Connect your Miner

TBD


Back to top

Copyright © 2024-2026 P2Poolv2 Developers. Distributed under the MIT or Apache-2.0 license.

Describes P2Poolv2 at commit dc5bb652 (2026-10-08).

This site uses Just the Docs, a documentation theme for Jekyll.