From b33fcdc06f1831954153ec5e33137d66b2f8ab43 Mon Sep 17 00:00:00 2001 From: Josh Godsiff Date: Fri, 8 Mar 2019 15:02:29 +1100 Subject: [PATCH 1/2] Added freebsd, darwin, linux, windows, 386, and amd64 to build targets. --- .travis.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index d4df7982..25b190c9 100644 --- a/.travis.yml +++ b/.travis.yml @@ -15,17 +15,18 @@ install: - ./elasticsearch-${ES_VERSION}/bin/elasticsearch -Epath.repo=/tmp & - export ELASTICSEARCH_URL=http://127.0.0.1:9200 - export TF_LOG=INFO + - go get github.com/mitchellh/gox - go get -v github.com/Masterminds/glide - cd $GOPATH/src/github.com/Masterminds/glide && git checkout v0.13.1 && go install && cd - - glide install script: - - go build -v + - gox -os "freebsd darwin linux windows" -arch "386 amd64" - wget -q --waitretry=1 --retry-connrefused -T 10 -O - $ELASTICSEARCH_URL - TF_ACC=1 go test -v -cover before_deploy: | # rename to match terraform provider conventions: # https://www.terraform.io/docs/configuration/providers.html#third-party-plugins - mv terraform-provider-elasticsearch "terraform-provider-elasticsearch_${TRAVIS_TAG}" + for file in terraform-provider-elasticsearch*; do mv "$file" "${file}_${TRAVIS_TAG}"; done deploy: provider: releases api_key: From 7992aee5b35db8b84505a506d94610ee07a3a52d Mon Sep 17 00:00:00 2001 From: Josh Godsiff Date: Mon, 11 Mar 2019 08:59:07 +1100 Subject: [PATCH 2/2] Use gox output param instead of manually moving binaries --- .travis.yml | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/.travis.yml b/.travis.yml index 25b190c9..70db969d 100644 --- a/.travis.yml +++ b/.travis.yml @@ -20,13 +20,9 @@ install: - cd $GOPATH/src/github.com/Masterminds/glide && git checkout v0.13.1 && go install && cd - - glide install script: - - gox -os "freebsd darwin linux windows" -arch "386 amd64" + - gox -os "freebsd darwin linux windows" -arch "386 amd64" -output="terraform-provider-elasticsearch_${TRAVIS_TAG}_{{.OS}}_{{.Arch}}" - wget -q --waitretry=1 --retry-connrefused -T 10 -O - $ELASTICSEARCH_URL - TF_ACC=1 go test -v -cover -before_deploy: | - # rename to match terraform provider conventions: - # https://www.terraform.io/docs/configuration/providers.html#third-party-plugins - for file in terraform-provider-elasticsearch*; do mv "$file" "${file}_${TRAVIS_TAG}"; done deploy: provider: releases api_key: