Skip to content

Instantly share code, notes, and snippets.

@0xobjectObject
Last active July 2, 2023 23:28
Show Gist options
  • Star 3 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save 0xobjectObject/f201f61eaf990f7d7da939d33a6c14a2 to your computer and use it in GitHub Desktop.
Save 0xobjectObject/f201f61eaf990f7d7da939d33a6c14a2 to your computer and use it in GitHub Desktop.

Multiple nodes on an existing Docker or reverse hybrid setup

This guide assumes you've read the introduction and have an already working Rocket Pool node using the default Docker project name rocketpool and default config path ~/.rocketpool and all the default ports. Modify accordingly if you changed anything.

If you aren't creating your second node, replace any occurrence of rocketpool2 and rp2 with the correct number (like rocketpool3 and rp3 for your third node).

Installation

To install rocketpool into the ~/.rocketpool2 directory, run

rocketpool s i -d -y -p ~/.rocketpool2

To comfortably access your different nodes, add an alias for each to the end of your ~/.profile file:

alias rp1='rocketpool -c ~/.rocketpool'
alias rp2='rocketpool -c ~/.rocketpool2'

I'd advise against creating an rp alias, so you don't accidentally run commands for the wrong node if you forget to type a number.

To load your new aliases, run

source ~/.profile

Initial configuration

To start configuring your new node, use the newly created alias and run

rp2 s c

You'll see the Config Wizard on your first run. Select the following options:

  1. Next
  2. Same network as your first node
  3. Externally Managed
  4. Enter http://rocketpool_eth1:8545 and ws://rocketpool_eth1:8546
  5. Select the consensus client you're using for your first node. Enter http://rocketpool_eth2:5052 (and http://rocketpool_eth2:5053 if you're using Prysm). Choose whatever you want for Graffiti and Doppelgänger Protection.
  6. If you have a working fallback setup, enter your details here.
  7. No metrics (for now).
  8. Review All Settings, don't save yet!

The next step is very important, don't miss it or stuff will break:

Select "Smartnode and TX Fees" and change the "Project Name" to rocketpool2. Press enter after making the change.

Now you can press ESC and select "Review Changes and Save". Make sure you see Project Name: rocketpool => rocketpool2 under "Smartnode Settings". If you do, you can save the settings and answer "yes" when asked to start the Smartnode services automatically.

Docker network setup

You need to add your existing execution and consensus clients to your rocketpool2_net network, or your new node won't be able to access them.

Edit ~/.rocketpool/override/eth1.yml so it looks like this:

services:
  eth1:
    x-rp-comment: Add your customizations below this line
    networks:
      - rocketpool2
networks:
  rocketpool2:
    name: rocketpool2_net
    external: true

Edit ~/.rocketpool/override/eth2.yml so it looks like this:

services:
  eth2:
    x-rp-comment: Add your customizations below this line
    networks:
      - rocketpool2
networks:
  rocketpool2:
    name: rocketpool2_net
    external: true

You'll need to add 4 additional lines to both files for each node you want to run. Restart your first node to apply the changes:

rp1 s start

Updating your nodes

You've successfully created a second Rocket Pool node on your computer. Please be aware that you'll need to update each node separately, and metrics won't work out of the box. Read this for more information.

After you've read the updating instructions linked above, you can continue with the Setting up a Wallet step in the official guides.

You'll need to use rp1 or rp2 instead of the rocketpool command in the future. Using rocketpool is the same as rp1.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment