forked from bors-ng/bors-ng
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.taskcluster.yml
112 lines (107 loc) · 4.2 KB
/
.taskcluster.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
version: 1
policy:
pullRequests: public
tasks:
# The bors build queue (build release)
- $if: 'tasks_for == "github-push" && event["ref"] in ["refs/heads/staging", "refs/heads/trying"]'
then:
provisionerId: 'proj-bors-ng'
workerType: 'ci'
deadline: {$fromNow: 1 day}
expires: {$fromNow: 1 year}
payload:
maxRunTime: 3600
image: "notriddle/docker-phoenix-elixir-test@sha256:b89a7faa6ac082cde241752c8ed1e1608c439678959c849fd0871dee8944222e"
command:
- /bin/bash
- '--login'
- '-c'
- >-
git clone ${event.repository.clone_url} repo && cd repo &&
git config advice.detachedHead false && git checkout ${event.after} &&
export MIX_ENV=prod &&
mix deps.get &&
npm install && npm run deploy &&
mix phx.digest &&
mix distillery.release --env=$MIX_ENV
metadata:
name: Bors-NG build release
description: 'Run a release using distillery'
owner: 'infra@bors.tech'
source: '${event.repository.clone_url}'
# The bors build queue (test suite)
- $if: 'tasks_for == "github-push" && event["ref"] in ["refs/heads/staging", "refs/heads/trying"]'
then:
provisionerId: 'proj-bors-ng'
workerType: 'ci'
deadline: {$fromNow: 1 day}
expires: {$fromNow: 1 year}
payload:
maxRunTime: 3600
image: "notriddle/docker-phoenix-elixir-test@sha256:b89a7faa6ac082cde241752c8ed1e1608c439678959c849fd0871dee8944222e"
command:
- /bin/bash
- '--login'
- '-c'
- >-
git clone ${event.repository.clone_url} repo && cd repo &&
git config advice.detachedHead false && git checkout ${event.after} &&
(sudo runuser -u postgres -- /usr/lib/postgresql/9.5/bin/postgres -D /etc/postgresql/9.5/main/ 2>&1 > /dev/null &) &&
sleep 10 &&
export MIX_ENV=test &&
mix do deps.get, test
metadata:
name: Bors-NG test suite
description: 'Run unit and integration tests with no browser and a mock GitHub API'
owner: 'infra@bors.tech'
source: '${event.repository.clone_url}'
# The bors build queue (static analysis)
- $if: 'tasks_for == "github-push" && event["ref"] in ["refs/heads/staging", "refs/heads/trying"]'
then:
provisionerId: 'proj-bors-ng'
workerType: 'ci'
deadline: {$fromNow: 1 day}
expires: {$fromNow: 1 year}
payload:
maxRunTime: 3600
image: "notriddle/docker-phoenix-elixir-test@sha256:b89a7faa6ac082cde241752c8ed1e1608c439678959c849fd0871dee8944222e"
command:
- /bin/bash
- '--login'
- '-c'
- >-
export MIX_ENV=dev &&
git clone ${event.repository.clone_url} repo && cd repo &&
git config advice.detachedHead false && git checkout ${event.after} &&
mix deps.get &&
mix dialyzer --halt-exit-status
metadata:
name: Bors-NG static analysis
description: 'Run static analysis (dialyzer)'
owner: 'infra@bors.tech'
source: '${event.repository.clone_url}'
# The pull request builder (static analysis)
- $if: 'tasks_for == "github-pull-request" && event["action"] in ["opened", "reopened", "synchronize"]'
then:
provisionerId: 'proj-bors-ng'
workerType: 'ci'
deadline: {$fromNow: 1 day}
expires: {$fromNow: 1 year}
payload:
maxRunTime: 3600
image: "notriddle/docker-phoenix-elixir-test@sha256:b89a7faa6ac082cde241752c8ed1e1608c439678959c849fd0871dee8944222e"
command:
- /bin/bash
- '--login'
- '-c'
- >-
git clone ${event.pull_request.head.repo.clone_url} repo && cd repo &&
git config advice.detachedHead false && git checkout ${event.pull_request.head.sha} &&
export MIX_ENV=dev &&
mix deps.get &&
mix dialyzer --halt-exit-status
metadata:
name: Bors-NG style checker
description: 'Run "build" against a pull request'
owner: 'nobody@users.noreply.github.com'
source: '${event.pull_request.head.repo.clone_url}'