Merge pull request #1466 from formych/patch-1

FIX: Cross-compile
This commit is contained in:
Tianon Gravi 2019-04-23 07:38:43 -07:00 committed by GitHub
commit ad78a08290
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 0 deletions

View File

@ -59,6 +59,7 @@ Alternatively, you can build for multiple platforms at once:
$ docker run --rm -it -v "$PWD":/usr/src/myapp -w /usr/src/myapp %%IMAGE%%:1.8 bash $ docker run --rm -it -v "$PWD":/usr/src/myapp -w /usr/src/myapp %%IMAGE%%:1.8 bash
$ for GOOS in darwin linux; do $ for GOOS in darwin linux; do
> for GOARCH in 386 amd64; do > for GOARCH in 386 amd64; do
> export GOOS GOARCH
> go build -v -o myapp-$GOOS-$GOARCH > go build -v -o myapp-$GOOS-$GOARCH
> done > done
> done > done