In this Guide, we contribute to the Drosera testnet by:
- Installing the CLI
- Setting up a vulnerable contract
- Deploying a Trap on testnet
- Connecting an operator to the Trap
- 2 CPU Cores
- 4 GB RAM
- 20 GB Disk Space
sudo apt-get update && sudo apt-get upgrade -ysudo apt install curl ufw iptables build-essential git wget lz4 jq make gcc nano automake autoconf tmux htop nvme-cli libgbm1 pkg-config libssl-dev libleveldb-dev tar clang bsdmainutils ncdu unzip libleveldb-dev -ysudo apt update -y && sudo apt upgrade -y
for pkg in docker.io docker-doc docker-compose podman-docker containerd runc; do sudo apt-get remove $pkg; done
sudo apt-get update
sudo apt-get install ca-certificates curl gnupg
sudo install -m 0755 -d /etc/apt/keyrings
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /etc/apt/keyrings/docker.gpg
sudo chmod a+r /etc/apt/keyrings/docker.gpg
echo \
"deb [arch="$(dpkg --print-architecture)" signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/ubuntu \
"$(. /etc/os-release && echo "$VERSION_CODENAME")" stable" | \
sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
sudo apt update -y && sudo apt upgrade -y
sudo apt-get install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin
# Test Docker
sudo docker run hello-worldcurl -L https://app.drosera.io/install | bashsource /root/.bashrcdroseraupcurl -L https://foundry.paradigm.xyz | bashsource /root/.bashrcfoundryupcurl -fsSL https://bun.sh/install | bashmkdir my-drosera-trapcd my-drosera-trapgit config --global user.email "Github_Email"
git config --global user.name "Github_Username"forge init -t drosera-network/trap-foundry-templatecurl -fsSL https://bun.sh/install | bash
bun installforge buildSkip warnings!
DROSERA_PRIVATE_KEY=xxx drosera apply-
Replace
xxxwith your EVM walletprivatekey(ensure it’s funded with Holesky ETH). -
When prompted, write
ofcand press Enter.
If you encounter rate-limiting errors (e.g., HTTP 429) or JSON-RPC errors (e.g., -32000) with the default RPC in drosera.toml, update the ethereum_rpc field to use an Infura RPC URL. Sign up at Infura, create a project, and get your Holesky endpoint (e.g., https://holesky.infura.io/v3/YOUR_INFURA_KEY).
Edit drosera.toml:
cd my-drosera-trap
nano drosera.tomlUpdate the ethereum_rpc line:
ethereum_rpc = "https://holesky.infura.io/v3/YOUR_INFURA_KEY"Save and re-run:
DROSERA_PRIVATE_KEY=xxx drosera applyConnect your Drosera EVM wallet: https://app.drosera.io/
Click on Traps Owned to see your deployed Traps OR search your Trap address.
Open your Trap on the Dashboard and click on Send Bloom Boost to deposit some Holesky ETH.
drosera dryruncd my-drosera-trap
nano drosera.tomlAdd the following codes at the bottom of drosera.toml:
private_trap = true
whitelist = ["Operator_Address"]- Replace
Operator_Addresswith your EVM walletPublic Addressbetween" "symbols. - Your
Public Addressis yourOperator_Address.
DROSERA_PRIVATE_KEY=xxx drosera apply- Replace
xxxwith your EVM walletprivatekey.
Your Trap should be private now with your operator address whitelisted internally.
cd ~curl -LO https://github.com/drosera-network/releases/releases/download/v1.16.2/drosera-operator-v1.16.2-x86_64-unknown-linux-gnu.tar.gztar -xvf drosera-operator-v1.16.2-x86_64-unknown-linux-gnu.tar.gz./drosera-operator --versionsudo cp drosera-operator /usr/bindrosera-operatordocker pull ghcr.io/drosera-network/drosera-operator:latestdrosera-operator register --eth-rpc-url https://ethereum-holesky-rpc.publicnode.com --eth-private-key PV_KEY- Replace
PV_KEYwith your Drosera EVM privatekey. Use the same wallet as your trap wallet.
sudo ufw allow ssh
sudo ufw allow 22
sudo ufw enable
sudo ufw allow 31313/tcp
sudo ufw allow 31314/tcpChoose one Installation Method:
- Method 1: Install using Docker
- Method 2: Install using SystemD
git clone https://github.com/0xmoei/Drosera-Network
cd Drosera-Network
cp .env.example .env
nano .env- Replace
your_evm_private_keywith your EVM wallet privatekey. - Replace
your_vps_public_ipwith your VPS public IP address.
docker compose up -dcd Drosera-Network
docker compose logs -fNo problem if you are receiving
WARN drosera_services::network::service: Failed to gossip message: InsufficientPeers
Enter this command in the terminal, but first replace:
PV_KEYwith your privatekey.VPS_IPwith your VPS IP (without anything else).- If using a local system, replace VPS IP with
0.0.0.0.
sudo tee /etc/systemd/system/drosera.service > /dev/null <<EOF
[Unit]
Description=drosera node service
After=network-online.target
[Service]
User=$USER
Restart=always
RestartSec=15
LimitNOFILE=65535
ExecStart=$(which drosera-operator) node --db-file-path $HOME/.drosera.db --network-p2p-port 31313 --server-port 31314 \
--eth-rpc-url https://ethereum-holesky-rpc.publicnode.com \
--eth-backup-rpc-url https://1rpc.io/holesky \
--drosera-address 0xea08f7d533C2b9A62F40D5326214f39a8E3A32F8 \
--eth-private-key PV_KEY \
--listen-address 0.0.0.0 \
--network-external-p2p-address VPS_IP \
--disable-dnr-confirmation true
[Install]
WantedBy=multi-user.target
EOFsudo systemctl daemon-reload
sudo systemctl enable drosera
sudo systemctl start droserajournalctl -u drosera.service -f!! No problem if you are receiving
WARN drosera_services::network::service: Failed to gossip message: InsufficientPeers
In the dashboard, click on Opt-in to connect your operator to the Trap.
Your node will start producing green blocks in the dashboard.







