range

If there were you, the world would be just right

安装golang

1、先安装 EPEL 源:

yum install epel -y

2、然后使用 源码 安装 Golang:

wget https://www.golangtc.com/static/go/1.9.2/go1.9.2.linux-amd64.tar.gz

3、环境变量:
在 /etc/profile 添加:

export GOPATH=/data/web/go
export GOBIN=$GOPATH/bin
export GOPKG=$GOROOT/pkg/tool/linux_amd64
export GOARCH=amd64
export GOOS=linux
export PATH=$PATH:/usr/local/go/bin

然后执行 source /etc/profile 使之生效。


阅读剩余部分...