-
Notifications
You must be signed in to change notification settings - Fork 0
/
.drone.star
48 lines (47 loc) · 965 Bytes
/
.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
def step(arch, node):
return {
"kind": "pipeline",
"name": "build-%s" % arch,
"type": "exec",
"trigger": {
"branch": [ "master" ]
},
"platform": {
"arch": arch
},
"steps": [
{
"name": "lint",
"commands": [ "nixpkgs-fmt --check ." ]
},
{
"name": "build",
"environment": {
"NIX_PATH": "nixpkgs=/nix/var/nix/profiles/per-user/root/channels/nixos",
"CACHIX_TOKEN": {
"from_secret": "CACHIX_TOKEN"
}
},
"commands": [
"cachix authtoken $CACHIX_TOKEN",
"bash build-cache.bash"
]
}
],
"node": node
}
def main(ctx):
return [
step("arm64", {
"os": "nixos",
"arch": "aarch64",
"type": "exec",
"hostname": "oracle"
}),
step("amd64", {
"os": "nixos",
"arch": "amd64",
"type": "exec",
"hostname": "wirecat"
})
]