cmd方式
https://blog.csdn.net/qq_33512078/article/details/86415727
cd 到需要编译的目录下
set GOARCH=amd64
set GOOS=linux
go build xxx.go
git方式
ENV CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build xx.go
cmd方式
https://blog.csdn.net/qq_33512078/article/details/86415727
cd 到需要编译的目录下
set GOARCH=amd64
set GOOS=linux
go build xxx.go
git方式
ENV CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build xx.go