2019-05-31 17:24:45 +03:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
cd $(dirname $0)
|
2019-06-04 15:49:39 +03:00
|
|
|
set -e # exit when any command fails
|
2019-05-31 17:24:45 +03:00
|
|
|
|
|
|
|
./down.sh
|
|
|
|
docker-compose build
|
2019-07-26 11:14:25 +03:00
|
|
|
docker network create --driver bridge ultimate || true
|
2019-07-16 17:12:33 +03:00
|
|
|
docker-compose up -d parity1 parity2 e2e
|
2019-05-31 17:24:45 +03:00
|
|
|
|
|
|
|
while [ "$1" != "" ]; do
|
|
|
|
if [ "$1" == "oracle" ]; then
|
2019-09-18 22:45:13 +03:00
|
|
|
docker-compose up -d redis rabbit oracle oracle-erc20 oracle-erc20-native oracle-amb
|
2019-05-31 17:24:45 +03:00
|
|
|
|
|
|
|
docker-compose run -d oracle yarn watcher:signature-request
|
|
|
|
docker-compose run -d oracle yarn watcher:collected-signatures
|
|
|
|
docker-compose run -d oracle yarn watcher:affirmation-request
|
|
|
|
docker-compose run -d oracle-erc20 yarn watcher:signature-request
|
|
|
|
docker-compose run -d oracle-erc20 yarn watcher:collected-signatures
|
|
|
|
docker-compose run -d oracle-erc20 yarn watcher:affirmation-request
|
2019-10-29 17:55:47 +03:00
|
|
|
docker-compose run -d oracle-erc20 yarn watcher:transfer
|
2019-05-31 17:24:45 +03:00
|
|
|
docker-compose run -d oracle-erc20-native yarn watcher:signature-request
|
|
|
|
docker-compose run -d oracle-erc20-native yarn watcher:collected-signatures
|
|
|
|
docker-compose run -d oracle-erc20-native yarn watcher:affirmation-request
|
2019-10-29 17:55:47 +03:00
|
|
|
docker-compose run -d oracle-erc20-native yarn watcher:transfer
|
2019-12-02 23:20:53 +03:00
|
|
|
docker-compose run -d oracle-erc20-native yarn watcher:half-duplex-transfer
|
|
|
|
docker-compose run -d oracle-erc20-native yarn worker:swap-tokens
|
2019-09-18 22:45:13 +03:00
|
|
|
docker-compose run -d oracle-amb yarn watcher:signature-request
|
|
|
|
docker-compose run -d oracle-amb yarn watcher:collected-signatures
|
|
|
|
docker-compose run -d oracle-amb yarn watcher:affirmation-request
|
2019-05-31 17:24:45 +03:00
|
|
|
docker-compose run -d oracle yarn sender:home
|
|
|
|
docker-compose run -d oracle yarn sender:foreign
|
|
|
|
fi
|
|
|
|
|
|
|
|
if [ "$1" == "ui" ]; then
|
|
|
|
docker-compose up -d ui ui-erc20 ui-erc20-native
|
2019-06-03 11:11:00 +03:00
|
|
|
|
2019-06-14 16:50:22 +03:00
|
|
|
docker-compose run -d -p 3000:3000 ui yarn start
|
|
|
|
docker-compose run -d -p 3001:3000 ui-erc20 yarn start
|
|
|
|
docker-compose run -d -p 3002:3000 ui-erc20-native yarn start
|
2019-06-03 11:11:00 +03:00
|
|
|
fi
|
|
|
|
|
2019-06-03 14:47:52 +03:00
|
|
|
if [ "$1" == "deploy" ]; then
|
|
|
|
docker-compose run e2e e2e-commons/scripts/deploy.sh
|
|
|
|
fi
|
|
|
|
|
2019-06-03 16:49:40 +03:00
|
|
|
if [ "$1" == "blocks" ]; then
|
|
|
|
node ./scripts/blocks.js &
|
|
|
|
fi
|
|
|
|
|
2019-06-27 10:57:45 +03:00
|
|
|
if [ "$1" == "monitor" ]; then
|
2019-11-13 09:51:11 +03:00
|
|
|
docker-compose up -d monitor monitor-erc20 monitor-erc20-native monitor-amb
|
2019-06-27 10:57:45 +03:00
|
|
|
fi
|
|
|
|
|
2019-07-17 11:14:58 +03:00
|
|
|
if [ "$1" == "native-to-erc" ]; then
|
2019-08-29 11:30:34 +03:00
|
|
|
../deployment-e2e/molecule.sh ultimate-native-to-erc
|
2019-07-17 11:14:58 +03:00
|
|
|
fi
|
|
|
|
|
2019-08-08 17:09:24 +03:00
|
|
|
if [ "$1" == "erc-to-native" ]; then
|
2019-08-29 11:30:34 +03:00
|
|
|
../deployment-e2e/molecule.sh ultimate-erc-to-native
|
2019-08-08 17:09:24 +03:00
|
|
|
fi
|
|
|
|
|
2019-08-20 11:19:42 +03:00
|
|
|
if [ "$1" == "erc-to-erc" ]; then
|
2019-08-29 11:30:34 +03:00
|
|
|
../deployment-e2e/molecule.sh ultimate-erc-to-erc
|
2019-08-20 11:19:42 +03:00
|
|
|
fi
|
|
|
|
|
2019-05-31 17:24:45 +03:00
|
|
|
shift # Shift all the parameters down by one
|
|
|
|
done
|