Add circleci parameter to build packages
This commit is contained in:
parent
284ab79a37
commit
5f88be022c
|
@ -73,8 +73,8 @@ cat $GOPATH/bin/telegraf | gzip > $CIRCLE_ARTIFACTS/telegraf.gz
|
||||||
go build -o telegraf-race -race -ldflags "-X main.version=${VERSION}-RACE" cmd/telegraf/telegraf.go
|
go build -o telegraf-race -race -ldflags "-X main.version=${VERSION}-RACE" cmd/telegraf/telegraf.go
|
||||||
cat telegraf-race | gzip > $CIRCLE_ARTIFACTS/telegraf-race.gz
|
cat telegraf-race | gzip > $CIRCLE_ARTIFACTS/telegraf-race.gz
|
||||||
|
|
||||||
eval "git describe --exact-match HEAD"
|
|
||||||
if [ $? -eq 0 ]; then
|
if git describe --exact-match HEAD; then
|
||||||
# install fpm (packaging dependency)
|
# install fpm (packaging dependency)
|
||||||
exit_if_fail gem install fpm
|
exit_if_fail gem install fpm
|
||||||
# install boto & rpm (packaging & AWS dependencies)
|
# install boto & rpm (packaging & AWS dependencies)
|
||||||
|
@ -84,4 +84,12 @@ if [ $? -eq 0 ]; then
|
||||||
echo $tag
|
echo $tag
|
||||||
exit_if_fail ./scripts/build.py --release --package --platform=all --arch=all --upload --bucket=dl.influxdata.com/telegraf/releases
|
exit_if_fail ./scripts/build.py --release --package --platform=all --arch=all --upload --bucket=dl.influxdata.com/telegraf/releases
|
||||||
mv build $CIRCLE_ARTIFACTS
|
mv build $CIRCLE_ARTIFACTS
|
||||||
|
elif [ -n "${PACKAGE}" ]; then
|
||||||
|
# install fpm (packaging dependency)
|
||||||
|
exit_if_fail gem install fpm
|
||||||
|
# install boto & rpm (packaging & AWS dependencies)
|
||||||
|
exit_if_fail sudo apt-get install -y rpm python-boto
|
||||||
|
unset GOGC
|
||||||
|
exit_if_fail ./scripts/build.py --package --platform=all --arch=all
|
||||||
|
mv build $CIRCLE_ARTIFACTS
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in New Issue