docs: Add BSD install script

This commit is contained in:
ValarDragon 2018-06-04 13:35:00 -07:00 committed by rigelrozanski
parent cd4499c15f
commit 40df73adc2
3 changed files with 47 additions and 1 deletions

View File

@ -1,7 +1,7 @@
# Install
The fastest and easiest way to install the Cosmos SDK binaries
is to run [this script](https://github.com/cosmos/cosmos-sdk/blob/develop/scripts/install.sh) on a fresh Ubuntu instance. Read the comments / instructions carefully (i.e., reset your terminal after running the script).
is to run [this script](https://github.com/cosmos/cosmos-sdk/blob/develop/scripts/install_sdk_ubuntu.sh) on a fresh Ubuntu instance. Similarly, you can run [this script](https://github.com/cosmos/cosmos-sdk/blob/develop/scripts/install_sdk_bsd.sh) on a fresh FreeBSD instance. Read the comments / instructions carefully (i.e., reset your terminal after running the script).
Cosmos SDK can be installed to
`$GOPATH/src/github.com/cosmos/cosmos-sdk` like a normal Go program:

View File

@ -0,0 +1,46 @@
#!/usr/bin/tcsh
# Just run tcsh install_sdk_bsd.sh
# XXX: this script is intended to be run from
# a fresh Digital Ocean droplet with FreeBSD
# upon its completion, you must either reset
# your terminal or run `source ~/.tcshrc`
# change this to a specific release or branch
set BRANCH=master
sudo pkg updatels
sudo pkg upgrade -y
sudo pkg install -y gmake
sudo pkg install -y git
# get and unpack golang
curl -O https://storage.googleapis.com/golang/go1.10.freebsd-amd64.tar.gz
tar -xvf go1.10.freebsd-amd64.tar.gz
# move go binary and add to path
mv go /usr/local
set path=($path /usr/local/go/bin)
# create the go directory, set GOPATH, and put it on PATH
mkdir go
echo "setenv GOPATH /root/go" >> ~/.tcshrc
setenv GOPATH /root/go
echo "set path=($path $GOPATH/bin)" >> ~/.tcshrc
source ~/.tcshrc
# get the code and move into repo
set REPO=github.com/cosmos/cosmos-sdk
go get $REPO
cd $GOPATH/src/$REPO
# build & install master
git checkout $BRANCH
gmake get_tools
gmake get_vendor_deps
gmake install
gmake install_examples