mirror of
https://github.com/lddsb/drone-dingtalk-message.git
synced 2026-06-14 05:13:05 +08:00
47 lines
938 B
YAML
47 lines
938 B
YAML
---
|
|
kind: pipeline
|
|
name: default
|
|
|
|
workspace:
|
|
base: /go
|
|
path: src/github.com/lddsb/drone-dingtalk-message
|
|
|
|
steps:
|
|
- name: build
|
|
image: golang
|
|
commands:
|
|
- go get -u github.com/golang/dep/cmd/dep
|
|
- dep ensure
|
|
- CGO_ENABLED=0 GOOS=linux go build -a -o drone-dingtalk-message .
|
|
- go test -race -coverprofile=coverage.txt -covermode=atomic
|
|
- ./drone-dingtalk-message -h
|
|
- name: codecov
|
|
image: plugins/codecov
|
|
when:
|
|
status:
|
|
- success
|
|
settings:
|
|
token:
|
|
from_secret: codecov_token
|
|
- name: publish
|
|
image: plugins/docker
|
|
when:
|
|
status:
|
|
- success
|
|
event:
|
|
- tag
|
|
settings:
|
|
repo: lddsb/drone-dingtalk-message
|
|
dockerfile: Dockerfile
|
|
tags:
|
|
- latest
|
|
- 1.0.0
|
|
username:
|
|
from_secret: docker_username
|
|
password:
|
|
from_secret: docker_password
|
|
|
|
trigger:
|
|
branch:
|
|
- master
|