forked from src-d/lookout
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.drone.yml
68 lines (56 loc) · 1.41 KB
/
.drone.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
workspace:
base: /go
path: src/github.com/src-d/lookout
branches: [master]
# ANCHORS
build: &build
image: golang:1.10-stretch
commands:
- make dependencies
- PKG_OS=linux DOCKER_OS=linux DOCKER_ARCH=amd64 make packages
debug: true
docker_image: &docker_image
group: docker
image: plugins/docker
registry: docker.io
repo: srcd/lookout
secrets: [ docker_username, docker_password ]
dockerfile: docker/Dockerfile
debug: true
helm_deploy: &helm_deploy
image: quay.io/ipedrazas/drone-helm:master-9b37211
skip_tls_verify: true
helm_repos: srcd-charts=https://src-d.github.io/charts/
chart: srcd-charts/lookout
chart-version: 0.7.0
release: lookout
tiller_ns: lookout
namespace: lookout
# PIPELINE STEPS
pipeline:
clone:
image: plugins/git
debug: true
# deployment to staging environment when master is pushed
build_stg:
<<: *build
when:
branch: [master]
event: [push]
docker_image_stg:
<<: *docker_image
# workaround for bug https://github.com/kubernetes/helm/issues/1707
tag: 'commit-${DRONE_COMMIT_SHA:0:7}'
when:
branch: [master]
event: [push]
helm_deploy_stg:
<<: *helm_deploy
prefix: STG
timeout: 900
secrets: [ STG_API_SERVER, STG_KUBERNETES_TOKEN ]
values: image.lookout.tag=commit-${DRONE_COMMIT_SHA:0:7}
values_files: [.helm-staging.yml]
when:
branch: [master]
event: [push]