-
Notifications
You must be signed in to change notification settings - Fork 6
/
.drone.yml
111 lines (101 loc) · 2.75 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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
kind: pipeline
name: default
type: docker
steps:
- name: restore-cache
image: drillster/drone-volume-cache
volumes:
- name: drone-cache
path: /cache
settings:
restore: true
mount:
- ./gradle_cache
- name: build-java
image: eclipse-temurin:17-jdk
environment:
GRADLE_USER_HOME: /drone/src/gradle_cache
TZ: Europe/London
commands:
- chmod +x gradlew
- ./gradlew test shadowJar
- name: publish
image: plugins/docker:19.03.8
settings:
registry: quay.io
repo: quay.io/fivium/dmda
tags:
- ${DRONE_BRANCH//\//-}-${DRONE_BUILD_NUMBER}
config:
from_secret: docker_config
when:
branch:
- master
- master-auto
- feature/**
event:
- push
- name: publish-helm-chart-master-auto
image: quay.io/fivium/drone-helm
settings:
chart_name: dmda
chart_version: 0.${DRONE_BUILD_NUMBER}.0
app_version: master-auto-${DRONE_BUILD_NUMBER}
environment:
AWS_ACCESS_KEY_ID: AKIA4K4CXHTZ7KAUZJWL
AWS_SECRET_ACCESS_KEY:
from_secret: aws_secret_access_key
when:
branch:
- master-auto
status:
- success
- name: publish-helm-chart-master
image: quay.io/fivium/drone-helm
settings:
chart_name: dmda
chart_version: ${DRONE_BUILD_NUMBER}.0.0
app_version: master-${DRONE_BUILD_NUMBER}
environment:
AWS_ACCESS_KEY_ID: AKIA4K4CXHTZ7KAUZJWL
AWS_SECRET_ACCESS_KEY:
from_secret: aws_secret_access_key
when:
branch:
- master
status:
- success
- name: sync-reports
image: alpine:3
commands:
- mkdir -p /var/webfiles/${DRONE_BUILD_NUMBER}
- cp -r build/reports /var/webfiles/${DRONE_BUILD_NUMBER}
volumes:
- name: webfiles
path: /var/webfiles
when:
status: [ success, failure ]
- name: rebuild-cache
image: drillster/drone-volume-cache
volumes:
- name: drone-cache
path: /cache
settings:
rebuild: true
mount:
- ./gradle_cache
volumes:
- name: webfiles
host:
path: /home/fivium/www/dmda
- name: drone-cache
host:
path: /home/fivium/drone-cache
---
kind: secret
name: docker_config
data: PoK0OAmT3gPGRPwx/I3Bb19pKUxCTiFhASs3/ItJxinc0WRWFUqbYE/hhgdkYnoTDIh839y3jN5NwB6U6x9up6cLZ2aXNWXs4BLxbCjhmUuNJXZpS3voYWdlDhFrslV+84DSLIQKCJogQfEgwuWtN5NgEHl/qoxN3IEboKK38lM8NHSRAChnPm8Oz4M5ocV47SCIXVchmQHdaidZOvRW6Mi1Lm9ktEewIzldzP+H0gnaXs2x3clgY2jxs2ugl77ClT0X3icvb1SqNgYZB7GIt0ieks5UPXfzQ5sZj/ItJz+YVqCSWMfCb/3XECj/ipB8bKHUa5UgRiTp3uAcBJYcIqR8S2ubdA==
---
kind: secret
name: aws_secret_access_key
data: rOhSJ7/HYVXu6ZLnG77zZIeJ12QHs2VXpU5YFPvLUrigOUzuVikrPHJNt1yzzSH2n+vgmrV8dxh2Ky4+vCdOG5SOhX4=