A convenience wrapper for running a node, using the Aleph Node docker image under the hood.
Note that this tool always maintains the latest versions for Testnet and Mainnet (and auto-updates itself). There should never be a reason to have it on anything else than the latest main
branch commit.
You will need docker
and wget
. If you are using Linux, we recommend that you add your user to the docker
group so that using docker
doesn’t require sudo access. You can find the instructions here.
Clone the repo at https://github.com/Cardinal-Cryptography/aleph-node-runner:
git clone [https://github.com/Cardinal-Cryptography/aleph-node](https://github.com/Cardinal-Cryptography/aleph-node-runner)
cd aleph-node-runner
Once inside the aleph-node-runner
folder, run:
./run_node.sh --name <your_nodes_name> --ip <your IP>
It might take quite some time before you actually get the node running: the script will first download required files, including a database snapshot (sized ~100GB). You can alternatively skip this step by providing the --sync_from_genesis
flag (see the 'Additional Options' section). The script will then run the node for you and you should start seeing some block-related output.
💡 The choice of
your_nodes_name
is entirely up to you but for the sake of more comprehensible logs please try using something unique and memorable.
💡 Instead of
--ip
,you can provide a domain by using--dns
.
The default is to run the node as a validator. Should you choose to run as an archivist instead, you need to supply the --archivist
flag:
./run_node.sh --archivist --name <your_nodes_name>
💡 To run as an archivist, you will need additional network config [TODO].
The script allows you to customize the run in several ways, as listed below:
--ip
: your public IP (this or--dns
is required)--dns
: your public domain address (this or--ip
is required)--data_dir
: specify the directory in which all of the chain data will be stored (defaults to~/.alephzero
)--mainnet
: join the Aleph Mainnet instead of the default Testnet--keep_containers
: don't stop or remove existingaleph-node
containers (by default the script does that to ensure minimal downtime)--sync_from_genesis
: by providing this option, you're choosing not to download and use a DB snapshot, but rather perform a full sync--build_only
: the script will only download and setup everything but will not actually run the binary in case you don't want to join the network yet--archivist
: (as described above) run the node as an archivist instead of a validator--name
: (as described above) set the name of the node. If you omit this option, one will be generated for you but it's not encouraged.--version
: manually override the version to run. It can be either a git tag liker-12.1
or a git short commit hash likeae34eb4213
.