Juno is a node which aims to help decentralise StarkNet, a prominent Ethereum Layer 2.
For its mission to be achieved, it needs people to start running their own node.
To become one of the early few making StarkNet better, read below.
In this short article we lay out the steps to get a Raspberry PI with a working Raspbian installation to run the Juno StarkNet node. We assume that you have access as a root user to the Pi.
At time of writing, both StarkNet and Juno are still in an early release. Expect this guide and required steps to change often!
The disk space issues are currently work in progress, and will be addressed in an upcoming new release.
- Get and Sync state from Layer 1 (Ethereum).
- Get and Sync state from API (Feeder Gateway).
- Store StarkNet State locally.
- Store StarkNet Transactions.
- Store StarkNet Blocks.
- Store the ABI and full code of StarkNet contracts.
- Ethereum-like JSON RPC API following this spec. Currently supported are:
starknet_getBlockWithTxHashes- Get block information with transaction hashes given the block id.
starknet_getBlockWithTxs- Get block information with full transactions given the block id.
starknet_getStateUpdate- Get the information about the result of executing the requested block.
starknet_getStorageAt- Get the value of the storage at the given address and key.
starknet_getTransactionByHash- Get the details and status of a submitted transaction.
starknet_getTransactionByBlockIdAndIndex- Get the details of a transaction by a given block id and index.
starknet_getTransactionReceipt- Get the transaction receipt by the transaction hash.
starknet_getClassHashAt- Get the contract class hash in the given block for the contract deployed at the given address.
starknet_getBlockTransactionCount- Get the number of transactions in a block given a block id.
starknet_call- Call a StarkNet function without creating a transaction.
starknet_blockNumber- Get the most recent accepted block number.
starknet_blockHashAndNumber- Get the most recent accepted block hash and number.
starknet_chainId- Return the currently configured StarkNet chain id.
starknet_pendingTransactions- Returns the transactions in the transaction pool, recognized by this sequencer.
starknet_syncing- Returns an object about the sync status, or false if the node is not synching.
- Prometheus Metrics.
- Dockerized app.
- Raspberry 4 (model B) - 4GB running Raspbian
- MicroSD card - 16GB+ (Class 10 Minimum) or SSD
- Power supply
- Internet connection (ethernet preferrable)
- USB keyboard, a monitor, and an HDMI cable to interact with the computer or ssh into the raspberry pi.
Get Golang 🦫
Ensure that your Raspberry Pi is up-to-date.
sudo apt update
sudo apt full-upgrade
Check the Golang download website for the latest armv6l version. At time of writing, we would download go 1.18.3.
wget https://go.dev/dl/go1.18.3.linux-armv6l.tar.gz -O go.tar.gz
Now extract the tarball into your /usr/local/ directory (root access required).
sudo tar -C /usr/local -xzf go.tar.gz
Add the following to your shell config (usually ~/.bashrc).
If you have no preferred text editor, you can use
nano ~/.bashrc to edit your bash config from the terminal.
X and then
Y to exit the nano text editor and save the file.
Finally, as your
.bashrc is only initialised when the shell is started, you need to source the new
~/.bashrc to update available commands.
You should now have a working Golang installation in your Raspberry Pi. You can check it typing:
Install Juno ⚙️
Clone the repository:
git clone https://github.com/NethermindEth/juno
Install Python dependencies
We are currently only support python
3.7, and we recommend use pyenv. To install it, you can follow this instruction:
- Install dependencies:
sudo apt-get update
sudo apt-get install make build-essential git patch zlib1g-dev clang \
openssl libssl-dev libbz2-dev libreadline-dev libsqlite3-dev llvm \
libncursesw5-dev xz-utils tk-dev libxml2-dev libxmlsec1-dev libffi-dev \
- Install pyenv:
curl https://pyenv.run | bash
- Add the following entries into your
eval "$(pyenv init --path)"
eval "$(pyenv virtualenv-init -)"
- Restart your shell:
- Install Python 3.7:
pyenv install 3.7.13
pyenv global 3.7.13
- Inside of the project folder, install Python dependencies:
$ pip install -r requirenments.txt
Installing Go dependencies
You can install all golang dependencies running the next command inside the project folder:
$ go get ./...
$ make juno
To synchronize with the StarkNet state from the centralized feeder gateway, run the following command:
# For Ethereum Goerli testnet
# For Ethereum Mainnet
$ ./build/juno --netowrk 1
To sync the state without relying on the feeder gateway, configure an Ethereum node and run the following command:
# For Ethereum Goerli testnet
$ ./build/juno --eth-node "<node-endpoint>"
# For Ethereum Mainnet
$ ./build/juno --netowrk 1 --eth-node "<node-endpoint>"
To view other available options please run
For more configuration details, check the config description.
When syncing the StarkNet state from a Raspberry Pi, we expect you to have at least 64GB. In case of you don't have
this space, you can run it using an SSD, ensuring that the property
db-path in the config or the flag
points to the external SSD:
And yes, you are now helping on the StarkNet decentralisation!