gorush/.drone.yml

88 lines
1.7 KiB
YAML
Raw Normal View History

workspace:
base: /srv/app
path: src/github.com/appleboy/gorush
clone:
git:
image: plugins/git
depth: 50
tags: true
pipeline:
build:
image: appleboy/golang-testing
secrets: [ codecov_token, android_test_token, android_api_key ]
environment:
- GOPATH=/srv/app
- PATH=$${PATH}:/srv/app/bin
commands:
- make deps
- make vet
- make lint
- make build
- make embedmd
- make test-vendor
2017-06-05 02:42:07 +00:00
- make misspell-check
- make fmt-check
- coverage all
# send coverage report
- make coverage
release:
image: appleboy/golang-testing
pull: true
environment:
GOPATH: /srv/app
TAGS: netgo
commands:
- make release
when:
event: [ tag ]
branch: [ refs/tags/* ]
2017-05-12 03:39:18 +00:00
publish_latest:
image: plugins/docker
pull: true
2017-05-12 03:39:18 +00:00
repo: ${DRONE_REPO}
tags: [ 'latest' ]
secrets: [ docker_username, docker_password ]
when:
2017-05-12 03:39:18 +00:00
event: [ push ]
branch: [ master ]
local: false
2017-05-12 03:39:18 +00:00
publish_tag:
image: plugins/docker
pull: true
2017-05-12 03:39:18 +00:00
repo: ${DRONE_REPO}
tags: [ '${DRONE_TAG}' ]
secrets: [ docker_username, docker_password ]
2017-05-12 03:39:18 +00:00
group: release
when:
2017-05-12 03:39:18 +00:00
event: [ tag ]
branch: [ refs/tags/* ]
local: false
2017-05-12 03:39:18 +00:00
release_tag:
image: plugins/github-release
2017-05-12 03:39:18 +00:00
secrets: [ github_release_api_key ]
group: release
files:
- dist/release/*
when:
event: [ tag ]
branch: [ refs/tags/* ]
2017-05-12 03:39:18 +00:00
local: false
facebook:
image: appleboy/drone-facebook
secrets: [ fb_page_token, fb_verify_token ]
pull: true
to: 1234973386524610
when:
status: [ success, failure ]
services:
redis:
image: redis:alpine