forked from grafana/dashboard-spec
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.drone.yml
47 lines (41 loc) · 1.02 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
kind: pipeline
type: docker
name: generate
steps:
- name: bundle
image: trotttrotttrott/swagger-cli:4.0.4
commands:
- make bundle
- name: generate
image: golang:1.14.6-alpine3.12
commands:
- go run . 7.0 jsonnet
- name: jsonnet fmt
image: bitnami/jsonnet:0.16.0
user: root
commands:
- find _gen/7.0/jsonnet/ -name '*.libsonnet' | xargs jsonnetfmt -i
- name: push
image: alpine/git:v2.26.2
environment:
DEPLOY_KEY:
from_secret: github_deploy_key
GIT_COMMITTER_EMAIL: [email protected]
GIT_COMMITTER_NAME: grafanabot
commands:
- git add -f .
- git commit -m '[drone] bundled specs and generated libraries'
- mkdir -p /root/.ssh
- echo "$DEPLOY_KEY" > /root/.ssh/id_rsa
- chmod 600 /root/.ssh/id_rsa
- touch /root/.ssh/known_hosts
- chmod 600 /root/.ssh/known_hosts
- ssh-keyscan -H github.com > /etc/ssh/ssh_known_hosts 2> /dev/null
- git push -f [email protected]:grafana/dashboard-spec HEAD:_gen
trigger:
event:
- push
branch:
- master
repo:
- grafana/dashboard-spec