Skip to content
A local testnet of go-spacemesh full nodes running the Spacemesh protocol and a functional CLI wallet. šŸ’¾ā°
Python Shell
Branch: master
Clone or download
Latest commit 737c831 Jul 18, 2019

Spacemesh logo

A programmable Cryptocurrency

Spacemesh Local Testnet (Localnet)

This repo contains the framework for running a 6 node Spacemesh testnet locally on one computer. It contains a setup script that clones and builds all the relevant repositories required for running a localnet. To learn more about the Spacemesh cryptocurrency visit .

Warning: The local testnet is an experimental alpha software in active development. It is built for developers who are comfortable with the command line, Docker, and dev env setup. You also need a strong modern dev computer to run it such as a Macbook Pro or a strong modern dev desktop computer. That said, we have tested it to work on all supported platforms and most of the issues we see are env setup.

Watch Youtube Video Tutorial



OS X setup

brew install git
brew install go
brew install python3
brew install docker
sudo easy_install pip
pip install virtualenv

Building from Source Code

The local testnet is 100% built from open source code from the Spacemesh github repos, and doesn't use any prepackaged pre-built binaries.

  1. Clone this repo to your computer
git clone
  1. From the shell run:
sudo chmod u+x
  1. Create virtual environment for running the testnet
virtualenv --python=python3 venv
  1. Activate virtual env and install requirements
source venv/bin/activate
pip install -r requirements.txt


Note that the localnet includes an instance of the POET service which is a CPU intensive process. For public testnets and the mainnet, you will not need to run a local POET service instance only 1 full node instance. You need a relatively strong dev box such as a modern MBP to run the localnet.

  1. Activate virtual env if you are not already in a virtual env session:
source venv/bin/activate
  1. Let it rip:

The testnet logs are available in the Logs directory.

Executing Transactions

  1. Open a new Terminal window and navigate to the CLIWallet directory in your go src directory:
cd $GOPATH/src/
  1. Run the wallet
  1. You should see a list of accounts. Choose one. e.g. enter anton
  2. Enter account to view Anton's account balance
  3. Enter transfer coins to transfer coin to another account and follow the on-screen instructions

Working with the Localnet


  • Docker cannot run without sudo: please refer to this guide
  • Container does not boot: make sure logs dir exists and has {user} rw permissions
  • Nodes stop producing blocks after 30 min - this is an issue with dockers DNS resolving, adding custom dns address to docker config should solve this problem

Linux Setup Tips

  • Follow the instructions in this guide to setup Docker desktop on Ubuntu

Questions, Comments, Feedback?

Windows Setup Tips (WIP)

  • You need to use Win 10 Pro - Win 10 Home is not supported because it doesn't support Docker Desktop.
  • You need to enable virtualization to run Docker desktop in Windows 10 Pro.
  • Use the git bash console to run things and not the command line.
  • Use these guides to setup python, pip and and virtual env:
    • to be added
You canā€™t perform that action at this time.