2017-07-04 07:45:25 +03:00
|
|
|
workspace:
|
2017-12-02 10:15:33 +03:00
|
|
|
base: /go/src
|
|
|
|
path: github.com/appleboy/drone-telegram
|
2017-07-04 07:45:25 +03:00
|
|
|
|
|
|
|
clone:
|
|
|
|
git:
|
|
|
|
image: plugins/git
|
|
|
|
depth: 50
|
|
|
|
tags: true
|
|
|
|
|
|
|
|
pipeline:
|
|
|
|
test:
|
|
|
|
image: appleboy/golang-testing
|
|
|
|
pull: true
|
2017-12-02 10:35:52 +03:00
|
|
|
secrets: [ telegram_token, telegram_to ]
|
2017-07-04 07:45:25 +03:00
|
|
|
commands:
|
|
|
|
- make vet
|
|
|
|
- make lint
|
|
|
|
- make test-vendor
|
|
|
|
- make misspell-check
|
|
|
|
- make test
|
|
|
|
- make coverage
|
2017-12-09 13:10:06 +03:00
|
|
|
|
|
|
|
build_linux_amd64:
|
|
|
|
image: appleboy/golang-testing
|
|
|
|
pull: true
|
|
|
|
group: build
|
|
|
|
commands:
|
|
|
|
- make build_linux_amd64
|
|
|
|
|
|
|
|
build_linux_i386:
|
|
|
|
image: appleboy/golang-testing
|
|
|
|
pull: true
|
|
|
|
group: build
|
|
|
|
commands:
|
|
|
|
- make build_linux_i386
|
|
|
|
|
|
|
|
build_linux_arm64:
|
|
|
|
image: appleboy/golang-testing
|
|
|
|
pull: true
|
|
|
|
group: build
|
|
|
|
commands:
|
|
|
|
- make build_linux_arm64
|
|
|
|
|
|
|
|
build_linux_arm:
|
|
|
|
image: appleboy/golang-testing
|
|
|
|
pull: true
|
|
|
|
group: build
|
|
|
|
commands:
|
|
|
|
- make build_linux_arm
|
2017-07-04 07:45:25 +03:00
|
|
|
|
2017-12-02 10:35:52 +03:00
|
|
|
codecov:
|
|
|
|
image: robertstettner/drone-codecov
|
|
|
|
secrets: [ codecov_token ]
|
|
|
|
files:
|
|
|
|
- .cover/coverage.txt
|
|
|
|
when:
|
|
|
|
event: [ push, pull_request ]
|
|
|
|
|
2017-07-04 07:45:25 +03:00
|
|
|
release:
|
|
|
|
image: appleboy/golang-testing
|
|
|
|
pull: true
|
|
|
|
commands:
|
|
|
|
- make release
|
|
|
|
when:
|
|
|
|
event: [ tag ]
|
|
|
|
|
2017-12-02 10:27:50 +03:00
|
|
|
publish_server:
|
2017-07-04 07:45:25 +03:00
|
|
|
image: plugins/docker
|
2017-12-02 10:27:50 +03:00
|
|
|
group: release
|
|
|
|
pull: true
|
2017-07-04 07:45:25 +03:00
|
|
|
secrets: [ docker_username, docker_password ]
|
2017-12-02 10:27:50 +03:00
|
|
|
default_tags: true
|
2017-12-02 11:22:32 +03:00
|
|
|
repo: ${DRONE_REPO}
|
2017-07-04 07:45:25 +03:00
|
|
|
when:
|
2017-12-02 10:27:50 +03:00
|
|
|
event: [ push, tag ]
|
|
|
|
local: false
|
2017-07-04 07:45:25 +03:00
|
|
|
|
2017-12-02 10:27:50 +03:00
|
|
|
publish_alpine:
|
2017-07-04 07:45:25 +03:00
|
|
|
image: plugins/docker
|
2017-12-02 10:27:50 +03:00
|
|
|
group: release
|
|
|
|
pull: true
|
|
|
|
dockerfile: Dockerfile.alpine
|
2017-07-04 07:45:25 +03:00
|
|
|
secrets: [ docker_username, docker_password ]
|
2017-12-02 10:27:50 +03:00
|
|
|
default_tags: true
|
|
|
|
default_suffix: alpine
|
2017-12-02 11:22:32 +03:00
|
|
|
repo: ${DRONE_REPO}
|
2017-07-04 07:45:25 +03:00
|
|
|
when:
|
2017-12-02 10:27:50 +03:00
|
|
|
event: [ push, tag ]
|
|
|
|
local: false
|
2017-07-04 07:45:25 +03:00
|
|
|
|
|
|
|
github:
|
|
|
|
image: plugins/github-release
|
2017-12-02 10:27:50 +03:00
|
|
|
pull: true
|
|
|
|
group: release
|
2017-07-05 11:11:52 +03:00
|
|
|
secrets: [ github_release_api_key ]
|
2017-07-04 07:45:25 +03:00
|
|
|
files:
|
|
|
|
- dist/release/*
|
|
|
|
when:
|
|
|
|
event: [ tag ]
|
|
|
|
|
2017-12-02 10:19:01 +03:00
|
|
|
discord:
|
|
|
|
image: appleboy/drone-discord
|
2017-07-04 07:45:25 +03:00
|
|
|
pull: true
|
2017-12-02 10:19:01 +03:00
|
|
|
secrets: [ discord_webhook_id, discord_webhook_token ]
|
2017-07-04 07:45:25 +03:00
|
|
|
when:
|
|
|
|
status: [ changed, failure ]
|