-
Notifications
You must be signed in to change notification settings - Fork 5
/
.drone.star
94 lines (93 loc) · 2.97 KB
/
.drone.star
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
def main(ctx):
return build(ctx)
def build(ctx):
return {
"kind": "pipeline",
"type": "docker",
"name": "build",
"steps": [
{
"name": "prepare-signing",
"image": "owncloudci/alpine",
"commands": [
"bash signing-preparation.sh",
],
"environment": {
"CODE_SIGNING_CERT_PW": {
"from_secret": "windows_cert_password",
},
"CODE_SIGNING_CERT": {
"from_secret": "windows_cert",
},
},
},
{
"name": "docker-images",
"image": "owncloudci/alpine",
"commands": [
"apk add make skopeo",
"make docker-images",
],
},
{
"name": "build-qpkg-only",
"image": "owncloudci/qnap-qpkg-builder:latest",
"pull": "always",
"commands": [
"patch /usr/share/qdk2/QDK/bin/qbuild fix_offline_signing.diff",
"make build-qpkg-only",
],
},
{
"name": "rename-unsigned",
"image": "owncloudci/alpine",
"commands": [
"bash rename-unsigned.sh",
],
},
{
"name": "list",
"image": "owncloudci/alpine",
"pull": "always",
"commands": [
"ls -lah build",
],
},
{
"name": "release",
"image": "plugins/github-release",
"pull": "always",
"environment": {
# set this manually, since this differs on our internal drone
"DRONE_REPO_NAME": "qnap-packaging",
"DRONE_REPO_OWNER": "owncloud",
"DRONE_REPO": "owncloud/qnap-packaging",
"DRONE_REPO_LINK": "https://github.com/owncloud/qnap-packaging"
},
"settings": {
"api_key": {
"from_secret": "github_token",
},
"files": [
"build/*",
],
"title": ctx.build.ref.replace("refs/tags/", ""),
"overwrite": True,
"prerelease": len(ctx.build.ref.split("-")) > 1,
},
"when": {
"ref": [
"refs/tags/**",
],
},
},
],
"depends_on": [],
"trigger": {
"ref": [
"refs/heads/master",
"refs/pull/**",
"refs/tags/**",
],
},
}