Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
38 lines (30 sloc) 1.48 KB
language: go
go:
- 1.10.x
cache:
directories:
- .gopath
sudo: required
services:
- docker
env:
- "PATH=/home/travis/gopath/bin:$PATH"
script:
- docker run -d --rm -p "36363:5432" -e POSTGRES_USER=postgres -e POSTGRES_PASSWORD=postgres
-e POSTGRES_DB=fhirbase postgres:10.4
- bash -c 'while ! nc -z localhost 36363 ; do sleep 1 ; done'
- PGUSER=postgres PGPASSWORD=postgres PGDATABASE=fhirbase PGPORT=36363 make test
- "[ ! -z \"$TRAVIS_TAG\" ] && git describe --tags > .version || echo 'non-tag build'"
- GOOS=linux GOARCH=amd64 BINSUFFIX=-linux-amd64 make
- GOOS=linux GOARCH=386 BINSUFFIX=-linux-386 make
- GOOS=windows GOARCH=amd64 BINSUFFIX=-windows-amd64.exe make
- GOOS=windows GOARCH=386 BINSUFFIX=-windows-386.exe make
- GOOS=darwin GOARCH=amd64 BINSUFFIX=-darwin-amd64 make
- echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin
- "[ ! -z \"$TRAVIS_TAG\" ] && make docker || echo 'non-tag build'"
before_install:
- curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
- curl -L https://github.com/tcnksm/ghr/releases/download/v0.12.0/ghr_v0.12.0_linux_amd64.tar.gz --output ghr.tar.gz && tar zxvf ghr.tar.gz
after_script:
- ghr_v0.12.0_linux_amd64/ghr --username fhirbase -r fhirbase --token $GITHUB_TOKEN --prerelease -replace --debug nightly-build bin/
- "[ ! -z \"$TRAVIS_TAG\" ] && ghr_v0.12.0_linux_amd64/ghr --username fhirbase -r fhirbase --token $GITHUB_TOKEN -n $TRAVIS_TAG --debug $TRAVIS_TAG bin/"
You can’t perform that action at this time.