⛏️ plebs be hashin ⚡
plebpool
is a pleb-friendly Bitcoin mining pool leveraging:
plebpool
takes a .toml
configuration file as input.
there is a sample config.toml
on the root of the repository, which the plebpool
binary will use as default.
assuming you cloned the repo, you can start plebpool
via:
$ cargo run
- SV1 Translator Endpoint
- SV2 Endpoint
- Mining Channel Manager
- Mining Channel Difficulty Manager
- Job Declaration Channel Manager
- Job Declaration Protocol
- Share Accounting
- ?
- Peer Manager
- Lightning Channel Manager
- ?
- Coinbase Manager
- BOLT12 Payout Manager
- ?
plebpool
uses a Nix flake to streamline the setup of the LN development environment. The flake.nix
file provides all necessary configurations and dependencies. Here’s an overview of what it does:
- Dependencies: The flake pulls in dependencies from
NixOS/nixpkgs
,rustshop/flakebox
, andnumtide/flake-utils
. - Development Shell: It sets up a development shell using
flakebox
utilities, including essential tools likeclightning
andbitcoind
. - Environment Configuration (
shellHook
):
- Creates required directories for the project and Bitcoin/Lightning setups.
- Defines convenient aliases for Bitcoin and Lightning CLI commands:
btc
,ln1
,ln2
- Ensures the Bitcoin daemon (
bitcoind
) is running and initializes a test wallet. - Starts two Lightning Network nodes (
ln1
andln2
) if they are not already active, facilitating a ready-to-use development environment.ln1 address
:127.0.0.1:19846
ln2 address
:127.0.0.1:15352
To use this flake, simply run:
$ nix develop
This will launch the development shell with all the configurations and tools set up as described.
You can interact with the nodes via:
$ ln1 getinfo
$ ln2 getinfo
And write the node_id
fields into config.toml
stratum-message-generator.sh
is used to automate SRI Message Generator tests.
This project was started by @plebhash, which is an active member on the Stratum Reference Implementation community.
All code is provided as FOSS (under Apache 2.0 + MIT), and @plebhash has no intention to:
- Create a business out of it
- Create a revenue stream from it
Given the low hashrate this pool will attract (if any), this implementation will never be meaningful economic competition on the Bitcoin mining landscape.
While a harsh critic could potentially label this as a LARP and a waste of time, @plebhash feels this is an important personal exercise with the goals of:
- walking the shoes of a community developer trying to consume SRI APIs
- creating community engagement with the pleb mining community, where a lot of FOSS ASIC is flourishing (e.g.: BitAxe)