Launching your parachain on Paseo Testnet
This guide is for onboarding a parachain to the Polkadot "Paseo" Testnet
Let's start by creating the accounts needed for launching the parachain.
Setting Up Accounts
First, we will need to set up a stash account to do transactions on Paseo to onboard our parachain.
There are multiple ways to generate keys (accounts) on Polkadot, such as:
PolkadotJs Signer or any other custodial
Account creation should be done securely, such as using an air-gapped computer.
Create a Stash Account Key
For the sake of this guide, we will use subkey:
Once downloaded,
subkey
does not need an internet connection to work.
Let's create the stash account key:
If you do not have docker installed, you can download the polkadot-sdk and run the following command instead:
You should get an output similar to:
This your key (Polkadot account). Save the secret phrase in a vault securely and never share it.
Now that we have a stash account, we need to fund this account with some tokens so that it has funds to perform transactions on behalf of the collator such as transactions related to connecting your parachain to the Paseo network.
Add the stash account to the Polkadot Signer extension so that you can see your account appear in the PolkadotJs Apps UI.
Go to the Polkadot Faucet and fund your account:
Cool. Our stash account is now funded on the Paseo Relay chain.
Create a Session Account Key
We now need to create one more account. In order for collators to produce blocks, they need to sign the block with a (session) key. We call this key the session key. This account is specifically created for block production.
Let's go ahead and create the session account key.
We can use subkey
to generate the keys for us.
Reminder that this should be done securely, such as using an air-gapped computer.
Save the secret phrase in a secure manner.
Parachain Onboarding
With the account and session keys created, we can now ready our parachain for onboarding.
Obtain the Parachain ID
To onboard our parachain we need to grab the next available parachain ID on Paseo. We can use PolkaotJs Apps and check the chain state for the next available parachain ID:
Make sure to note down the
paraId
. We will be using this in our next step
Creating the chain spec for the parachain
Let's create a chain spec for our parachain:
Build your parachain for release:
Create the chain spec:
This will output the following:
Your parachain's chain specification file
The plain text and the raw version e.g.
chain-spec.json
andchain-spec-raw.json
Your parachain's initial genesis state e.g.
para-4024-genesis-state
Your parachain's Wasm runtime e.g.
para-4024.wasm
For more advanced customization
pop build spec --help
Open the chain-spec.json
file in your editor.
Make sure to edit your chain spec and:
add your account and session keys
specify the starting balance of specific accounts
add the account that will be the sudo account for your parachain
It should look similar to the below:
Since we have modified our chain spec, we will need to re-generate the raw chain spec:
And re-generate the genesis state and wasm:
We are now ready to run our parachain's collator node to sync with Paseo and start producing blocks.
Requesting a Slot on Paseo
We are now ready to create an issue on Paseo's Github requesting to onboard our parachain:
Once you have been confirmed and given a slot, you can start running your collators.
Running the Collator
In order to run your parachain's collator node you will need the raw chain spec that our local Paseo network is using.
You can download that here:
Make sure to select the tag version that Paseo is running, download the zip, and you will find the paseo.raw.json
file inside the zip folder.
We will also need to create a node-key for your collator:
Alternatively you can use Polkadot SDK binary instead of a Docker image:
Run the collator with the following command:
A note on hardware requirements:
Choose ports that are not in use.
We now need to insert the session key into our running collator:
It will take time for your collator to sync with the local Paseo Relay chain.
Once it is fully synced, block production will start.
Congrats!
Next Steps
For next steps, you can try the following:
Designate one collator as the bootnode for the parachain's network
Add a second collator
Resources
Learning Resources
🧑🏫 To learn about Polkadot in general, Polkadot.network website is a good starting point.
⭕ Learn more about parachains here.
🧑🔧 For technical introduction, here are the Polkadot SDK documentation resources.
Technical Support
Create a question and tag it with "
pop
"Share the StackExchange question in our Pop Support Telegram channel
Last updated