This guide will help you set up your validator and participate in Masternode Staking. By following these steps, you'll stake your STRAX tokens, receive liquid staking tokens (mSTRAX), and use them as collateral on the Masternode dApp—earning dual rewards as both a validator operator and a Masternode participant.
Understanding the role of each component is key to a successful setup:
The Ejector Service acts as an intermediary between your validator and the staking network. Its primary functions include:
- Withdrawal & Emergency Handling: Managing withdrawals and addressing validator issues automatically.
The staking-deposit-cli tool is used for generating validator credentials and deposit data. Its key tasks are:
- Key Generation: Creating a secure mnemonic and generating unique validator keys (keystores).
- Deposit Data Creation: Producing JSON files that serve as proof of deposit and link your validator to the staking protocol.
The Stratis Launcher simplifies the process of configuring and managing your validator host. You can set up your validator host using the latest release from the stratis-node repository. It provides:
- User-Friendly Interface: A simple platform for uploading validator keys and managing staking operations.
- Validator Management: Automated configuration and integration of the required components.
- Monitoring & Updates: Real-time insights into validator status, performance, and rewards.
These components work together to create a robust and secure environment for Masternode Staking.
- SSH Access: Ensure you have SSH access to your host.
- Basic Linux Knowledge: Familiarity with terminal commands is recommended.
- STRAX Tokens: You will need 1,000,000 STRAX for Mainnet staking (or 100,000 tSTRAX for testing via the Stratis EVM Faucet).
Before using the Stratis Launcher, SSH into your host and follow these steps:
Update and upgrade your packages, then install the required dependencies:
apt update && apt upgrade -y
apt install -y git build-essential libssl-dev zlib1g-dev libbz2-dev \
libreadline-dev libsqlite3-dev wget curl llvm libncurses5-dev \
libncursesw5-dev xz-utils tk-dev libffi-dev liblzma-dev \
software-properties-common supervisor
-
Clone PyEnv into your home directory:
git clone https://github.com/pyenv/pyenv.git ~/.pyenv
-
Configure environment variables.
Add the following lines to your~/.bashrc
or~/.zshrc
file:export PYENV_ROOT="$HOME/.pyenv" export PATH="$PYENV_ROOT/bin:$PATH" eval "$(pyenv init --path)" eval "$(pyenv init -)"
-
Reload your shell:
source ~/.bashrc
-
Install Python 3.10 and set it as the global version:
pyenv install 3.10 pyenv global 3.10
-
Download, extract, and configure Go:
wget https://go.dev/dl/go1.23.5.linux-amd64.tar.gz rm -rf /usr/local/go tar -C /usr/local -xzf go1.23.5.linux-amd64.tar.gz export PATH=$PATH:/usr/local/go/bin source ~/.bashrc
Clone the repositories that contain the tools needed for your validator:
git clone https://github.com/stratisproject/staking-deposit-cli
git clone https://github.com/stratisproject/lss-ejector
-
Navigate to the
staking-deposit-cli
directory:cd staking-deposit-cli
-
Build and install using:
make build_linux ./deposit.sh install
-
Navigate to the ejector directory:
cd ../lss-ejector/
-
Build and install the ejector:
make install
-
Navigate to the staking-deposit-cli directory:
cd ../staking-deposit-cli
-
Run the key generation script with the execution address parameter:
For the beta network, run:./deposit.sh new-mnemonic --execution_address 0x00A6A303B2085857f04d700DF780dcEe72fc7048
Note: This execution address is specific to the beta network. For Mainnet, as the protocol is not deployed, there is no defined execution address.
-
You will be prompted to provide the following inputs:
- Number of Validators:
- Auroria: The collateral requirement is 100,000 STRAX. Define 5 validators (5 x 20,000 STRAX).
- Mainnet: The collateral requirement is 1,000,000 STRAX. Define 50 validators (50 x 20,000 STRAX).
- Withdrawal Recipient Address:
- For the beta network, set this value to:
0x00A6A303B2085857f04d700DF780dcEe72fc7048
- Important: Do not change this value or use a personal address. For Mainnet, as the protocol is not deployed, there is no address to use. Failure to set this address correctly will result in activation failure.
- For the beta network, set this value to:
- Network/Chain Name:
- Enter the correct network name (e.g.,
auroria
for Auroria,stratis
for Mainnet).
- Enter the correct network name (e.g.,
- Password:
- Choose a secure password to protect your validator keystore(s).
Note: The field for "Amount a validator must deposit" is no longer needed and should be omitted.
- Number of Validators:
-
Important:
- Record the generated mnemonic phrase and password securely.
- The script will create a
validator_keys
directory and outputdeposit_data.json
. - Keep these safe and copy to your local machine. Later we will upload the
validator_keys
via the Stratis Launcher and thedeposit_data.json
will be used to record your validators within the Masternode Staking protocol.
-
Create an Ejector configuration file:
Open or create the configuration file for Supervisor:vi /etc/supervisor/conf.d/ejector.conf
-
Paste the following configuration snippet (replace
<keystore_password>
with your password):[program:lss-ejector] command=lss-ejector start \ --execution_endpoint=http://localhost:8545 \ --consensus_endpoint=http://localhost:3500 \ --keys_dir=/root/staking-deposit-cli/validator_keys \ --staking_address=0x00A6A303B2085857f04d700DF780dcEe72fc7048 environment=KEYSTORE_PASSWORD=<keystore_password> redirect_stderr=true stdout_logfile=/var/log/supervisor-lss-ejector.log stdout_logfile_maxbytes=500MB stdout_logfile_backups=10 autostart=true startretries=10 stopwaitsecs=60
Important: Be sure to set your password value here:
environment=KEYSTORE_PASSWORD=<keystore_password>
-
Reload Supervisor to apply the new configuration:
supervisorctl reread supervisorctl update
To set up your validator host, use the latest release from the stratis-node repository.
This Stratis Launcher streamlines the process of uploading your validator keys and managing staking operations. Download and install the appropriate release from the repository, connect to the host we've configured and then upload your keys via the Staking Tab.
-
Deposit Collateral:
- Navigate to the Masternode Staking Beta.
- Deposit the required collateral (100,000 STRAX).
-
Receive Liquid Tokens:
- Upon deposit confirmation, you will receive an equivalent amount of liquid Masternode Staking tokens (mSTRAX).
-
Upload Deposit Data:
- Upload the
deposit_data
JSON file generated in Step 2 to link your validator with your staking deposit.
- Upload the
-
Deposit mSTRAX Tokens:
- Visit the Masternode dApp.
- Deposit your mSTRAX tokens as collateral to register on the Masternode Protocol.
-
Earn Dual Rewards:
- Once registered, you will earn rewards both for operating your validator and for being a member of the Masternode contract.
By following these detailed steps and understanding the role of each component, you'll be well-prepared to set up your validator host, configure essential services, and participate in Masternode Staking to maximize your yield.
Happy Masternode Staking!