All Projects → aviaviavi → Legion

aviaviavi / Legion

Licence: mit
Simple blockchain server written in haskell

Programming Languages

haskell
3896 projects

Projects that are alternatives of or similar to Legion

Firo
The privacy-focused cryptocurrency
Stars: ✭ 528 (-12.15%)
Mutual labels:  blockchain
Chain33
高度模块化, 遵循 KISS原则的区块链开发框架
Stars: ✭ 551 (-8.32%)
Mutual labels:  blockchain
Kelp
Kelp is a free and open-source trading bot for the Stellar DEX and 100+ centralized exchanges
Stars: ✭ 580 (-3.49%)
Mutual labels:  blockchain
Paper
On self sovereign human identity.
Stars: ✭ 537 (-10.65%)
Mutual labels:  blockchain
Skycoin
Skycoin Core and Wallet
Stars: ✭ 549 (-8.65%)
Mutual labels:  blockchain
Dtube
📺 d.tube app. A full-featured video sharing website, decentralized.
Stars: ✭ 569 (-5.32%)
Mutual labels:  blockchain
Token Profile
Blockchain coin and token profile collection
Stars: ✭ 518 (-13.81%)
Mutual labels:  blockchain
Ethereum Org Website
Ethereum.org is a primary online resource for the Ethereum community.
Stars: ✭ 591 (-1.66%)
Mutual labels:  blockchain
Awesome Blockchain Articles
A collection of awesome blockchain articles. Good learning resources about blockchain.
Stars: ✭ 552 (-8.15%)
Mutual labels:  blockchain
Status Go
The Status module that consumes go-ethereum
Stars: ✭ 579 (-3.66%)
Mutual labels:  blockchain
Btcpool Abandoned
backend of pool.btc.com
Stars: ✭ 541 (-9.98%)
Mutual labels:  blockchain
Ethql
A GraphQL interface to Ethereum 🔥
Stars: ✭ 547 (-8.99%)
Mutual labels:  blockchain
Beam
Beam: Scalable Confidential Cryptocurrency. Leading the way to Confidential DeFi
Stars: ✭ 571 (-4.99%)
Mutual labels:  blockchain
Eos Go
EOS.IO Go API library
Stars: ✭ 531 (-11.65%)
Mutual labels:  blockchain
Blockchain
区块链 - 中文资源
Stars: ✭ 5,574 (+827.45%)
Mutual labels:  blockchain
Go Iost
Official Go implementation of the IOST blockchain
Stars: ✭ 523 (-12.98%)
Mutual labels:  blockchain
Elrond Go
⚡ Elrond-GO: The official implementation of the Elrond protocol, written in golang.
Stars: ✭ 560 (-6.82%)
Mutual labels:  blockchain
Ethlance
Ethlance is the first job market platform built entirely on the Ethereum blockchain. Free to use forever!
Stars: ✭ 598 (-0.5%)
Mutual labels:  blockchain
Dcrd
Decred daemon in Go (golang).
Stars: ✭ 587 (-2.33%)
Mutual labels:  blockchain
Lisk Desktop
🖥 Lisk graphical user interface for desktop
Stars: ✭ 575 (-4.33%)
Mutual labels:  blockchain

Legion - a simple blockchain implementation

Build Status

An as-simple-as-possible blockchain server inspired by naivechain, but written in Haskell. Spinning up several Legion nodes creates a peer to peer network that syncronizes the block chain across the network.

Prereqs: To compile from source, you'll need stack.

Alternatively, you can get a precompiled pre-release binary. Note: if you download the binary from github, you'll need to mark it executable by running:

$ chmod +x legion-exe

Usage:

$ stack exec legion-exe [http port] [p2p port] [optional: `seedhost:seedP2PPort`]

Examples:

$ stack exec legion-exe 8001 9001

By default, legion will log what it's doing to standard out. In another terminal window:

$ stack exec legion-exe 8002 9002 localhost:9001

Alternatively, you grab the binaries from the github releases, and run that directly rather than via stack exec

The 3rd argument tells the node where a seed node can be found to bootstrap the connection to the peer to peer network. The current state of the (valid) blockchain will be fetched from all servers, and it will automatically keep itself updated and post its own updated to others.

Now that 2 nodes are now synced, and you can view the current chain from either node at http://localhost:$httpPort/chain, eg http://localhost:8001/chain

Add a new block to the blockchain via a POST request to /block:

$ curl -H "Content-Type: application/json" -X POST -d '{"blockBody": "this is the data for the next block"}' http://localhost:8001/block
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].