From 8e576f924b5996963896464deed69d94d00d737f Mon Sep 17 00:00:00 2001 From: Shivam Sharma Date: Wed, 16 Aug 2023 12:37:27 +0530 Subject: [PATCH] add : use chain name for heimdalld service when using mainnet/mumbai --- src/setup/devnet/index.js | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/setup/devnet/index.js b/src/setup/devnet/index.js index a0dd0e03..b4cc2bcc 100644 --- a/src/setup/devnet/index.js +++ b/src/setup/devnet/index.js @@ -746,6 +746,17 @@ export class Devnet { 'sudo mv ~/bor.service /lib/systemd/system/' ], { stdio: getRemoteStdio() }) + if (this.config.network) { + const chain = this.config.network + await execa('ssh', [ + '-o', 'StrictHostKeyChecking=no', '-o', 'UserKnownHostsFile=/dev/null', + '-i', '~/cert.pem', + `${this.config.devnetBorUsers[i]}@${this.config.devnetBorHosts[i]}`, + // eslint-disable-next-line + `sed -i "s|\\/var/lib/heimdall/config/genesis.json|${chain}|g" ~/heimdalld.service` + ], { stdio: getRemoteStdio() }) + } + await execa( 'ssh', [