Last active
May 24, 2018 16:59
-
-
Save zramsay/1dfe058f7bd19afe459ae9fdf0cf46c1 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# XXX: this script is meant to be used only on a fresh Ubuntu 16.04 instance | |
# and has only been tested on Digital Ocean | |
sudo apt-get update --yes | |
sudo apt-get upgrade --yes | |
# get and unpack golang | |
curl -O https://storage.googleapis.com/golang/go1.10.linux-amd64.tar.gz | |
tar -xvf go1.10.linux-amd64.tar.gz | |
sudo apt-get install make gcc --yes | |
## move go and add binary to path | |
mv go /usr/local | |
echo "export PATH=\$PATH:/usr/local/go/bin" >> ~/.profile | |
## create the GOPATH directory, set GOPATH and put on PATH | |
mkdir goApps | |
echo "export GOPATH=/root/goApps" >> ~/.profile | |
echo "export PATH=\$PATH:\$GOPATH/bin" >> ~/.profile | |
source ~/.profile | |
## get the code and move into it | |
REPO1=github.com/hyperledger/burrow | |
REPO2=github.com/monax/bosmarmot | |
go get $REPO1 | |
go get $REPO2 | |
mkdir $GOPATH/bin | |
# build it all | |
cd $GOPATH/src/$REPO1 && make build | |
mv $GOPATH/src/$REPO1/bin/* $GOPATH/bin | |
cd $GOPATH/src/$REPO2 && make build | |
mv $GOPATH/src/$REPO2/bin/* $GOPATH/bin | |
# install solc | |
sudo add-apt-repository ppa:ethereum/ethereum --yes | |
sudo apt-get update --yes | |
sudo apt-get install solc --yes | |
# start the keys server | |
monax-keys server 2>keys.log & | |
# burrow some stuff | |
burrow spec --participant-accounts=1 --full-accounts=1 > genesis-spec.json | |
burrow configure --genesis-spec=genesis-spec.json > burrow.toml | |
burrow start --validator-index=0 2>burrow.log & | |
# deploy | |
cd $GOPATH/src/github.com/monax/bosmarmot/monax/tests/jobs_fixtures | |
# pick an app you want to test/deploy and `cd` into its directory | |
# run this command manually after adding your validator address | |
# bos pkgs do --keys="http://localhost:4767" --chain-url="tcp://localhost:46657" --address=0A40DC874BC932B78AC390EAD1C1BF33469597AB |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment