bradleystachurski / go-spacemesh

Go Implementation of the Spacemesh blockmesh p2p node. 💾⏰💪

Home Page:https://spacemesh.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Spacemesh logo  

Blockmesh Operating System

Go Report Card

Browse Gitcoin Bounties

go-spacemesh

💾⏰💪 Thanks for your interest in this open source project. This is the go implementation of the Spacemesh p2p node. Spacemesh is a decentralized blockchain computer using a new race-free consensus protocol that doesn't involve energy-wasteful proof of work. We aim to create a secure and scalable decentralized computer formed by a large number of desktop PCs at home. We are designing and coding a modern blockchain platform from the ground up for scale, security and speed based on the learnings of the achievements and mistakes of previous projects in this space.

To learn more about Spacemesh head over to our wiki.

Motivation

SpacemeshOS is designed to create a decentralized blockchain smart contracts computer and a cryptocurrency that is formed by connecting the home PCs of people from around the world into one virtual computer without incurring massive energy waste and mining pools issues that are inherent in other blockchain computers, and provide a provably-secure and incentive-compatible smart contracts execution environment. Spacemesh OS is designed to be ASIC-resistant and in a way that doesn’t give an unfair advantage to rich parties who can afford setting up dedicated computers on the network. We achieve this by using a novel consensus protocol and optimize the software to be most effectively be used on home PCs that are also used for interactive apps.

What is this good for?

Provide dapp and app developers with a robust way to add value exchange and other value related features to their apps at scale. Our goal is to create a truly decentralized cryptocoin that fulfills the original vision behind bitcoin to become a secure trustless store of value as well as a transactional currency with extremely low transaction fees.

Target Users

go-spacemesh is designed to be installed and operated on users' home PCs to form one decentralized computer.

Project Status

Development is currently focused on 3 main node core components:

  1. The p2p/networking - the project includes a modern and robust p2p protocol for use by components up the stack.
  2. The POST/blockmesh based consensus layer - Spacemesh protocol implementation, utilizing the p2p capabilities.
  3. App scaffolding - supporting functionality such as config, repl, cli and cross platform packaging.

Over the last few months, we had good progress on #1 and #3 and we are now starting to focus on #2.

Contributing

Thank you for considering to contribute to the go-spacemesh open source project. We welcome contributions large and small and we actively accept contributions.

NEW! Get crypto awarded for your contribution by working on one of our gitcoin funded issues.

Diggin' Deeper

Please read the Spacemesh full FAQ.

High Level Design

Client Software Architecture

Getting

Install Go 1.11 or later for your platform.

git clone git@github.com:spacemeshos/go-spacemesh.git

-- or --

Fork the project from https://github.com/spacemeshos/go-spacemesh

Since the project uses Go 1.11's Modules it's best to place the code outside your $GOPATH. Read this for alternatives.

Setting Up Local Environment

Before building we need to install protoc (ProtoBuf compiler) and some tools required to generate ProtoBufs. Do this by running:

make install

This will invoke setup_env.sh which supports Linux and MacOS. On other platforms it should be straightforward to follow the steps in this script manually.

Building

To build go-spacemesh for your current system architecture, from the project root directory, use:

make build

This will (re-)generate protobuf files and build the go-spacemesh binary, saving it in the project root directory.

To build a binary for a specific architecture directory use:

make darwin | linux | windows

Platform-specific binaries are saved to the /build directory.

Running

./go-spacemesh

Testing

make test

or

make cover

Docker

A Dockerfile is included in the project allowing anyone to build and run a docker image:

docker build -t spacemesh .
docker run -d --name=spacemesh spacemesh

Next Steps...

Got Questions?

About

Go Implementation of the Spacemesh blockmesh p2p node. 💾⏰💪

https://spacemesh.io

License:MIT License


Languages

Language:Go 97.8%Language:Assembly 1.5%Language:Shell 0.4%Language:Makefile 0.1%Language:Dockerfile 0.1%