Add a deploy stage, go 1.8 only, that builds all architectures.

This commit is contained in:
David Anderson 2017-05-20 23:39:18 -07:00
parent 6bb7a1413d
commit 507b9e46f1

View File

@ -12,7 +12,6 @@ install:
- go get github.com/golang/lint/golint
script:
# It seems Travis, in an attempt to be helpful, nukes GOARCH=x if we
# pass it as such in the build matrix. So, because we really actually
# want the arch to change, we have to do this layer of
@ -26,6 +25,44 @@ script:
- "if [ \"$GOARCH\" = \"amd64\" ]; then go vet $(glide novendor); fi"
- "if [ \"$GOARCH\" = \"amd64\" ]; then glide novendor | xargs -n1 golint; fi"
jobs:
include:
- stage: deploy
go: 1.8
install:
- go get github.com/Masterminds/glide
- gem install fpm
script:
- glide install
- GOARCH=amd64 go build -o pixiecore.amd64 ./cmd/pixiecore
- GOARCH=386 go build -o pixiecore.386 ./cmd/pixiecore
- GOARCH=arm go build -o pixiecore.arm ./cmd/pixiecore
- fpm -s dir -t deb -n pixiecore -v $(date '+%Y%m%d%H%M%S')
--architecture amd64
--license Apache2 --vendor "David Anderson <dave@natulte.net>"
--maintainer "David Anderson <dave@natulte.net>"
--description "All-in-one PXE booting" --url "https://github.com/google/netboot"
--directories /usr/share/doc/pixiecore
./pixiecore.amd64=/usr/bin/pixiecore
./pixiecore/pixiecore.service=/usr/share/doc/pixiecore/pixiecore.service.example
- fpm -s dir -t deb -n pixiecore -v $(date '+%Y%m%d%H%M%S')
--architecture i386
--license Apache2 --vendor "David Anderson <dave@natulte.net>"
--maintainer "David Anderson <dave@natulte.net>"
--description "All-in-one PXE booting" --url "https://github.com/google/netboot"
--directories /usr/share/doc/pixiecore
./pixiecore.386=/usr/bin/pixiecore
./pixiecore/pixiecore.service=/usr/share/doc/pixiecore/pixiecore.service.example
- fpm -s dir -t deb -n pixiecore -v $(date '+%Y%m%d%H%M%S')
--architecture armhf
--license Apache2 --vendor "David Anderson <dave@natulte.net>"
--maintainer "David Anderson <dave@natulte.net>"
--description "All-in-one PXE booting" --url "https://github.com/google/netboot"
--directories /usr/share/doc/pixiecore
./pixiecore.arm=/usr/bin/pixiecore
./pixiecore/pixiecore.service=/usr/share/doc/pixiecore/pixiecore.service.example
env:
matrix:
- MY_GOARCH=amd64