Skip to content
This repository has been archived by the owner on Apr 27, 2024. It is now read-only.
/ slush Public archive

The Slush SDK allows you to spin up L3s on Starknet

License

Notifications You must be signed in to change notification settings

slushsdk/slush

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Slush SDK

license

The Slush SDK allows you to spin up L3s on Starknet.

For now this entails running Tendermint nodes and linking them to light clients on Starknet. This repo contains the modified Tendermint files as well as the Cairo contracts (modelled on Tendermint-Sol).

Send transactions to tendermint with the ABCI-CLI.


Requirements

Tool version
Go 1.17
Cairo 0.10.3
Starknet Devnet 0.4.2
Protostar 0.9.1
Python (with pyenv) 3.9

Before installing Starknet Devnet on M1 check this thread.


Starting a single local node

Clone this repo

git clone https://github.com/slushsdk/slush.git && cd slush

Build the binary:

make build

If using testnet (alpha-goerli):

Write your Argent/Braavos wallet account's private key in hex format into a file called pkey:

echo "0x..." > pkey

Use the init command with the --network testnet and --account-address flags:

./build/slush init validator --home ./valdata --network testnet --account-address 0x...

If using local devnet (starknet-devnet):

Start Starknet devnet with --seed 42:

starknet-devnet --seed 42

Write the first pre-deployed account's private key into a file called seed42pkey:

echo "0xbdd640fb06671ad11c80317fa3b1799d" > seed42pkey

Use the init command with:

./build/slush init validator --home ./valdata

Start the local node:

./build/slush start --proxy-app=kvstore --home ./valdata

Cleanup:

make clean && rm -rf ./valdata

Starting a testnet with watcher nodes on a different machines

You can deploy on alpha-goerli testnet.

On your chosen validator node:

Write your Argent/Braavos wallet private key into pkey file:

echo "0x..." > pkey

Build the binary:

make build

Init:

./build/slush init validator --home ./valdata --network testnet --account-address 0x...

Run the inputs for the non-validator nodes. Execute the output on the non-validator nodes:

python multiple-non-validator-node-steps.py

And you also need to start the validator node on the original machine, with:

./build/slush start --home ./valdata --proxy-app=kvstore

Initialize a non-validator node with the outputs of the multiple-non-validator-node-steps.py script. These will look like:


Initialize the non-validator node.

./build/slush init full --home ./valdata

Copy the content of the valdata/config/genesis.json file from the validator node to the valdata/config folder of the other non-validator computers.

Run the following command to start a non-validator node:

./build/slush start --home ./valdata --proxy-app=kvstore --p2p.persistent-peers "SOME-LONG-ADDRESS@SOME-IP:26656"

Cleanup:

make clean && rm -rf ./valdata

Roadmap

Our roadmap is here.

Join us!

We are looking for exciting engineers to join!