GithubHelp home page GithubHelp logo

kirk-baird / forest Goto Github PK

View Code? Open in Web Editor NEW

This project forked from chainsafe/forest

1.0 0.0 0.0 10.97 MB

🌲 Rust Filecoin Node Implementation

License: Apache License 2.0

Rust 99.76% Makefile 0.14% Shell 0.04% Dockerfile 0.06%

forest's Introduction

build status Apache License MIT License Discord Twitter

Forest is an implementation of Filecoin written in Rust. The implementation will take a modular approach to building a full Filecoin node in two parts — (i) building Filecoin’s security critical systems in Rust from the Filecoin Protocol Specification, specifically the virtual machine, blockchain, and node system, and (ii) integrating functional components for storage mining and storage & retrieval markets to compose a fully functional Filecoin node implementation.

Current development should be considered a work in progress.

Our crates:

crate description
blockchain Chain structures and syncing functionality
crypto Verification and signature definitions
encoding Forest encoding and decoding
ipld IPLD data model for content-addressable data
node Networking synchronization and storage
vm State transition and actors, message and address definitions

Dependencies

rustc >= 1.46.0

Usage

# Clone repository
git clone --recursive https://github.com/chainsafe/forest
cd forest

# Install binary to $HOME/.cargo/bin and run node
make install
forest

OpenCL, hwloc and a compatible assembly linker (ex. clang) are also required to build Filecoin proofs.

Config

Run the node with custom config and bootnodes

forest --config /path/to/your_config.toml

Example of config options available:

data_dir = "<directory for all chain and networking data>"
genesis_file = "<relative file path of genesis car file>"

[network]
listening_multiaddr = "<multiaddress>"
bootstrap_peers = ["<multiaddress>"]

Example of a multiaddress: "/ip4/54.186.82.90/tcp/1347/p2p/12D3K1oWKNF7vNFEhnvB45E9mw2B5z6t419W3ziZPLdUDVnLLKGs"

Logging

The Forest logger uses Rust's log filtering options with the RUST_LOG environment variable.
For example:

RUST_LOG="debug,forest_libp2p::service=info" forest

Will show all debug logs by default, but the forest_libp2p::service logs will be limited to info

Testing

# To run base tests
cargo test # use `make test-release` for longer compilation but faster execution

# To pull serialization vectors submodule and run serialization and conformance tests
make test-vectors

# To run all tests and all features enabled
make test-all

Joining the testnet

Build with the interopnet config with:

make interopnet

# Run and import past the state migrations to latest network version
./target/release/forest --import-snapshot ./types/networks/src/interopnet/snapshot.car

Importing the snapshot only needs to happen during the first run. Following this, to restart the daemon run:

./target/release/forest

Documentation

https://chainsafe.github.io/forest/

Contributing

ChainSafe Security Policy

Reporting a Security Bug

We take all security issues seriously, if you believe you have found a security issue within a ChainSafe project please notify us immediately. If an issue is confirmed, we will take all necessary precautions to ensure a statement and patch release is made in a timely manner.

Please email us a description of the flaw and any related information (e.g. reproduction steps, version) to security at chainsafe dot io.

License

Forest is dual licensed under MIT + Apache 2.0.

forest's People

Contributors

austinabell avatar ec2 avatar dutterbutter avatar rajarupansampanthan avatar timvermeulen avatar gregthegreek avatar flodesi avatar staticallytypedanxiety avatar snaumov avatar cryptoquick avatar ansermino avatar creativcoder avatar connormullett avatar huitseeker avatar dignifiedquire avatar vmx avatar amerameen avatar ayushmishra2005 avatar chainsafesystems avatar neithanmo avatar

Stargazers

Kirk Baird avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.