Skip to content

ParaState/substrate-ssvm-node

Repository files navigation

Substrate SSVM Node build

The primary objective of this project was to bring the Ethereum flavored WebAssembly (EWASM) runtime to Substrate. It enables developer collaboration between the Ethereum and Polkadot/Substrate ecosystems, and promotes inter-blockchain interoperability at the application level. You can now create a Substrate node (or Polkadot parachain) that supports the deployment and execution of EWASM smart contracts.

The project has a few components and dependencies.

  1. The EWASM Test Guide shows how to use the official EWASM test suite to verify the SSVM EWASM engine.
  2. The ssvm-evmc project provides a Rust EVMC binding for SSVM. (crates.io)
  3. The rust-ssvm project provides a Rust interface on SSVM. (crates.io)
  4. The pallet-ssvm project creates a "pallet" (or substrate package) that uses rust-ssvm as the substrate node's EWASM engine. (crates.io)
  5. The substrate-ssvm-node project (this project) provides a full ssvm-node that incorporates the pallet-ssvm.

Getting Started

Environment (Docker)

We provide a docker image secondstate/substrate-ssvm for building and running the Substrate SSVM Node.

> docker pull secondstate/substrate-ssvm

Build and Run Substrate SSVM Node

> git clone https://github.com/second-state/substrate-ssvm-node.git
> docker run -it --rm \
  --name substrate-ssvm \
  -v $(pwd):/root/node \
  -w /root/node \
  -p 9944:9944 \
  secondstate/substrate-ssvm
(docker) cd substrate-ssvm-node
(docker) make init
(docker) make build
(docker) cargo run --release --bin ssvm-node -- --dev --ws-external

Interact with Substrate SSVM Node

You can use the Substrate Web Interface(Polkadot.js) to connect with the node.

We provide a demo video to show that how polkadot.js interacts with our nodes.

And the detailed steps can be found in this tutorial.