Use Drone as the CI with a working pipeline (#28)

This commit is contained in:
Matthias Loibl 2019-04-23 14:26:40 +02:00 committed by GitHub
parent ccabc9707c
commit 18923f2dfc
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
29 changed files with 2677 additions and 5 deletions

54
.drone.jsonnet Normal file
View file

@ -0,0 +1,54 @@
{
_config+:: {
golang: 'golang:1.12',
},
kind: 'pipeline',
name: 'build',
platform: {
os: 'linux',
arch: 'amd64',
},
local golang = {
name: 'golang',
image: $._config.golang,
pull: 'always',
environment: {
CGO_ENABLED: '0',
GO111MODULE: 'on',
},
when: {
event: {
exclude: ['tag'],
},
},
},
steps: [
golang {
name: 'gomod',
commands: [
'go mod vendor',
'git diff --exit-code',
],
},
golang {
name: 'build',
commands: [
'make build',
'make test',
],
},
golang {
name: 'generate',
commands: [
'make check-license',
'make generate',
'git diff --exit-code',
],
},
],
}