Skip to content

Configure statemine bridge on e2e startup#829

Merged
alistair-singh merged 13 commits into
mainfrom
alistair/add-statemine
May 15, 2023
Merged

Configure statemine bridge on e2e startup#829
alistair-singh merged 13 commits into
mainfrom
alistair/add-statemine

Conversation

@alistair-singh

@alistair-singh alistair-singh commented May 11, 2023

Copy link
Copy Markdown
Contributor

Cumulus companion: Snowfork/cumulus#24

Adds scripts that will set up the ethereum bridge in the statemine pallet.

Resolves: SNO-433, SNO-493

Some scripts are copied over from the cumulus repo and edited.

@alistair-singh alistair-singh requested review from doubledup, vgeddes and yrong and removed request for vgeddes and yrong May 12, 2023 09:13
console.log(`Generating addExporterConfig from RPC endpoint: ${endpoint} to outputFile: ${outputFile} based on bridgedNetwork: ${bridgedNetwork}, bridgeConfig: ${bridgeConfig}`);
connect(endpoint)
.then((api) => {
const call = api.tx.bridgeTransfer.addExporterConfig(JSON.parse(bridgedNetwork), JSON.parse(bridgeConfig));

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Taken from cumulus repo but edited here to treat bridgedNetwork as JSON as it can be a complex type such as { "Ethereum": { "chainId": 1 } } as opposed to a simple string like "Wococo".

echo ""
echo "--------------------------------------------------"

npx polkadot-js-api \

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Adapted from cumulus repo scripts. Uses npx to launch node applications instead of expecting it to be in the PATH as a global tool.

@vgeddes vgeddes left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1

@yrong yrong left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@alistair-singh alistair-singh merged commit 1218377 into main May 15, 2023
@alistair-singh alistair-singh deleted the alistair/add-statemine branch May 15, 2023 08:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants