Files
plugin-drone-helm/.drone.yml
T
2017-07-25 15:53:05 +03:00

59 lines
1.4 KiB
YAML

workspace:
base: /go
path: src/github.com/ipedrazas/drone-helm
pipeline:
test:
image: golang:1.8
commands:
- go get
- go test -cover -coverprofile=coverage.out
compile:
image: golang:1.8
commands:
- export PATH=$PATH:/go/bin
- go build -ldflags "-s -w -X main.build=$DRONE_BUILD_NUMBER" -a -tags netgo
build_docker_image:
image: docker:17.05
environment:
- DOCKER_HOST=tcp://127.0.0.1:2375
- TAG=${DRONE_BRANCH}-${DRONE_COMMIT_SHA:0:7}
commands:
- docker login -u="${QUAY_USERNAME}" -p="${QUAY_PASSWORD}" quay.io
- docker build -t image .
- docker tag image quay.io/ipedrazas/drone-helm:latest
- docker tag image quay.io/ipedrazas/drone-helm:${TAG}
- docker push quay.io/ipedrazas/drone-helm
# when:
# event: [push]
# branch: [master]
slack:
image: plugins/slack
channel: deploys
username: drone
template: >
{{ build.author }} finished building *<http://drone.sohohousedigital.com/SohoHouse/{{ repo.name }}/{{ build.number }}|{{ build.branch }} ({{ build.number }})>* of {{ repo.name }} with a {{ build.status }} status
services:
dind:
image: docker:17.05-dind
privileged: true
command:
- "-s"
- "overlay"
plugin:
name: drone-helm
desc: Execute helm to
type: deploy
image: quay.io/ipedrazas/drone-helm
labels:
- deploy
- kubernetes
- helm