Build

This tutorial explains the process of building and running InfraDID parachain.

Before you begin

Before you begin, make sure to do the following:

The InfraDID Chain

If you have completed the previous tutorial, you should have the InfraRelayChain repository on your local machine.

  1. Open your computer's terminal shell.

  2. Execute the following command to clone InfraDID chain repository:

    git clone https://github.com/InfraBlockchain/infra-did-substrate

    This command clones the develop branch.

  3. Execute the following command to navigate to the root of the node template directory:

    cd infra-did-substrate

    Create a new branch for your work:

    git switch -c my-learning-branch-yyyy-mm-dd

    Replace yyyy-mm-dd with your desired identifier. We recommend using a numeric year-month-day format. For example:

    git switch -c my-learning-branch-2023-03-01
  4. Compile the node template with the following command:

    cargo build --release

    Always use the --release flag for optimized builds. The first compilation may take some time to complete. When it's finished, you'll see a line similar to this:

    Finished release [optimized] target(s) in 11m 23s

Starting a Local Node

Once the node is compiled, you're ready to set up the relay chain and InfraDID chain in a local environment using the ZombieNet.

To start the local InfraDID chain, follow these steps:

  1. Check the ZombieNet configuration:

    Ensure that the default_command paths for relaychain and parachains match existing paths in your local environment. If they don't match, adjust them to fit your local setup.

  2. Execute the following command to run ZombieNet and set up the relay chain and chain:

  3. If everything is running successfully, you will see a terminal shell similar to the one below:

    zombienet
  4. (Optional) If you want to check the nodes of InfraDID chain, you can find logs similar to this:

Next steps

Last updated