readme update on generating your own node-template (#16)
Added readme for generating your own substrate node templatemain
parent
9e02251a9c
commit
1d6e830474
30
README.md
30
README.md
|
@ -24,7 +24,7 @@ cargo build --release
|
||||||
|
|
||||||
## Run
|
## Run
|
||||||
|
|
||||||
### Single node development chain
|
### Single Node Development Chain
|
||||||
|
|
||||||
Purge any existing developer chain state:
|
Purge any existing developer chain state:
|
||||||
|
|
||||||
|
@ -40,7 +40,7 @@ Start a development chain with:
|
||||||
|
|
||||||
Detailed logs may be shown by running the node with the following environment variables set: `RUST_LOG=debug RUST_BACKTRACE=1 cargo run -- --dev`.
|
Detailed logs may be shown by running the node with the following environment variables set: `RUST_LOG=debug RUST_BACKTRACE=1 cargo run -- --dev`.
|
||||||
|
|
||||||
### Multi-node local testnet
|
### Multi-Node Local Testnet
|
||||||
|
|
||||||
If you want to see the multi-node consensus algorithm in action locally, then you can create a local testnet with two validator nodes for Alice and Bob, who are the initial authorities of the genesis chain that have been endowed with testnet units.
|
If you want to see the multi-node consensus algorithm in action locally, then you can create a local testnet with two validator nodes for Alice and Bob, who are the initial authorities of the genesis chain that have been endowed with testnet units.
|
||||||
|
|
||||||
|
@ -74,3 +74,29 @@ cargo run -- \
|
||||||
```
|
```
|
||||||
|
|
||||||
Additional CLI usage options are available and may be shown by running `cargo run -- --help`.
|
Additional CLI usage options are available and may be shown by running `cargo run -- --help`.
|
||||||
|
|
||||||
|
### Advanced: Generate Your Own Substrate Node Template
|
||||||
|
|
||||||
|
A substrate node template is always based on a certain version of Substrate. You can inspect it by
|
||||||
|
opening [Cargo.toml](Cargo.toml) and see the template referred to a specific Substrate commit(
|
||||||
|
`rev` field), branch, or version.
|
||||||
|
|
||||||
|
You can generate your own Substrate node-template based on a particular Substrate
|
||||||
|
version/commit by running following commands:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# git clone from the main Substrate repo
|
||||||
|
git clone https://github.com/paritytech/substrate.git
|
||||||
|
cd substrate
|
||||||
|
|
||||||
|
# Switch to a particular branch or commit of the Substrate repo your node-template based on
|
||||||
|
git checkout <branch/tag/sha1>
|
||||||
|
|
||||||
|
# Run the helper script to generate a node template.
|
||||||
|
# This script compiles Substrate and takes a while to complete. It takes a relative file path
|
||||||
|
# from the current dir. to output the compressed node template.
|
||||||
|
.maintain/node-template-release.sh ../node-template.tar.gz
|
||||||
|
```
|
||||||
|
|
||||||
|
Noted though you will likely get faster and more thorough support if you stick with the releases
|
||||||
|
provided in this repository.
|
||||||
|
|
Loading…
Reference in New Issue