Skip to content

Commit

Permalink
Merge pull request #4 from Shard-Labs/feature-bsc-reveiw
Browse files Browse the repository at this point in the history
fixes for rainbow bridge feedback 1
  • Loading branch information
3alpha committed Jul 16, 2021
2 parents 7386a26 + a9e5dd8 commit 3ab6d10
Show file tree
Hide file tree
Showing 5 changed files with 220 additions and 155 deletions.
8 changes: 5 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,12 @@ start-bsc:
cli/index.js clean
cli/index.js prepare
cli/index.js start near-node
cli/index.js start binance-smart-chain
cli/index.js start binance-smart-chain \
--eth-node-url https://data-seed-prebsc-1-s1.binance.org:8545 \
--eth-master-sk 0x2bdd21761a483f71054e14f5b827213567971c676928d9a1808cbfa4b7501200

# deploy contracts
full-bsc-contracts:
full-contracts:
cli/index.js init-near-contracts
cli/index.js init-eth-ed25519
cli/index.js init-eth-client --eth-client-lock-eth-amount 1000 --eth-client-lock-duration 10
Expand Down Expand Up @@ -61,6 +63,6 @@ build-eth-client:
cd contracts/near/eth-client && sudo ./build.sh

test-eth-client:
cd contracts/near/eth-client && ./test.sh
cd contracts/near/eth-client && sudo ./test.sh

.PHONY: help init yarn-init gen-contracts start-bsc full-bsc-contracts light-bsc-contracts start-relayer stop-all build-eth-client test-eth-client start-ethash
12 changes: 10 additions & 2 deletions cli/commands/start/binance-smart-chain.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,17 @@ class StartBinanceSmartChainNodeCommand {
nearClientValidateHeader = 'true'
}

if (ethNodeUrl === '') {
throw new Error('--eth-node-url not set')
}

if (ethMasterSk === '') {
throw new Error('--eth-master-sk not set')
}

return {
ethNodeUrl: ethNodeUrl !== '' ? ethNodeUrl : 'https://data-seed-prebsc-1-s1.binance.org:8545',
ethMasterSk: ethMasterSk !== '' ? ethMasterSk : '0x2bdd21761a483f71054e14f5b827213567971c676928d9a1808cbfa4b7501200',
ethNodeUrl: ethNodeUrl,
ethMasterSk: ethMasterSk,
nearClientValidateHeader: nearClientValidateHeader,
nearClientValidateHeaderMode: 'bsc'
}
Expand Down
Loading

0 comments on commit 3ab6d10

Please sign in to comment.