-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathinit-multi.sh
43 lines (33 loc) · 1.18 KB
/
init-multi.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
#!/bin/bash
echo "updating linux"
sudo apt-get update
sudo apt -y install curl unzip make git
echo "installing go"
curl -O https://dl.google.com/go/go1.10.2.linux-amd64.tar.gz
sudo tar -C /usr/local -xzf go1.10.2.linux-amd64.tar.gz
echo "sourcing go"
echo -e "\nexport PATH=\$PATH:/usr/local/go/bin:~/gopath/bin" >> ~/.bash_profile
. ~/.bash_profile
echo "installing protobuff"
export PROTOBUF_VERSION=3.5.1
curl -OL https://github.com/google/protobuf/releases/download/v${PROTOBUF_VERSION}/protoc-${PROTOBUF_VERSION}-linux-x86_64.zip
sudo unzip -o protoc-${PROTOBUF_VERSION}-linux-x86_64.zip -d /usr/local
sudo chmod +x /usr/local/bin/protoc
echo "installing go deps"
mkdir -p ~/gopath/bin
export GOPATH=~/gopath
curl https://raw.githubusercontent.com/golang/dep/master/install.sh > install.sh
. ./install.sh
echo "installing loom"
curl -OL https://storage.googleapis.com/private.delegatecall.com/loom/linux/build-209/loom
chmod +x loom
export GOPATH=~/gopath
export PATH=$GOPATH/bin:$PATH
export GOPATH=$GOPATH:`pwd`
./loom init
touch ./loom.yml
echo 'QueryServerHost: "tcp://0.0.0.0:9999"' >> ./loom.yml
echo "installation successful"
exit 0
# echo "running loom blockchain"
# ../../loom run