Skip to content

Commit

Permalink
Merge pull request #22 from keep-network/refer-local-ecdsa-from-tbtc
Browse files Browse the repository at this point in the history
Symlink local keep-ecdsa artifacts for tBTC
  • Loading branch information
nkuba authored Jul 31, 2020
2 parents fe3ce5d + 08f6d7e commit d0efb57
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 11 deletions.
10 changes: 1 addition & 9 deletions install-tbtc-dapp.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,18 +11,10 @@ WORKDIR=$PWD

printf "${LOG_START}Starting tBTC dApp deployment...${LOG_END}"

printf "${LOG_START}Preparing keep-ecdsa artifacts...${LOG_END}"

cd $WORKDIR/keep-ecdsa

cd solidity
ln -sf build/contracts artifacts

printf "${LOG_START}Preparing tbtc artifacts...${LOG_END}"

cd $WORKDIR/tbtc
cd "$WORKDIR/tbtc/solidity"

cd solidity
ln -sf build/contracts artifacts

printf "${LOG_START}Updating tbtc.js configuration...${LOG_END}"
Expand Down
18 changes: 16 additions & 2 deletions install-tbtc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,11 @@ done

printf "${LOG_START}Starting tBTC deployment...${LOG_END}"

printf "${LOG_START}Using $BTC_NETWORK Bitcoin network${LOG_END}"

cd "$WORKDIR/relay-genesis"
npm install

printf "${LOG_START}Using $BTC_NETWORK Bitcoin network${LOG_END}"

if [ "$BTC_NETWORK" == "testnet" ]; then
# Deploy TestnetRelay instead of the defaull MockRelay.
printf "${LOG_START}Updating testnet relay configuration...${LOG_END}"
Expand All @@ -39,6 +39,20 @@ if [ "$BTC_NETWORK" == "testnet" ]; then
jq '.init.bitcoinTest |= fromjson' relay-config.json > relay-config.json.tmp && mv relay-config.json.tmp relay-config.json
fi

printf "${LOG_START}Preparing keep-ecdsa artifacts...${LOG_END}"

cd "$WORKDIR/keep-ecdsa/solidity"

ln -sf build/contracts artifacts

printf "${LOG_START}Updating tBTC configuration...${LOG_END}"

cd "$WORKDIR/tbtc/solidity"

KEEP_ECDSA_DIR="$WORKDIR/keep-ecdsa/solidity" jq '.dependencies."@keep-network/keep-ecdsa" = env.KEEP_ECDSA_DIR' package.json > package.json.tmp && mv package.json.tmp package.json

printf "${LOG_START}Running install script...${LOG_END}"

cd "$WORKDIR/tbtc"

# Run tBTC install script. Answer with ENTER on emerging prompt.
Expand Down

0 comments on commit d0efb57

Please sign in to comment.