forked from envoyproxy/envoy
-
Notifications
You must be signed in to change notification settings - Fork 0
/
stages.yml
148 lines (138 loc) · 4.63 KB
/
stages.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
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
parameters:
## Build stages
# NB: all stages _must_ depend on `env`
- name: buildStageDeps
displayName: "Build stage dependencies"
type: object
default:
- env
- prechecks
- name: checkStageDeps
displayName: "Check stage dependencies"
type: object
default:
- env
- linux_x64
- name: concurrencyChecks
displayName: "Check concurrency"
type: number
default: 10
- name: concurrencyPrechecks
displayName: "Prechecks concurrency"
type: number
default: 10
## Timeouts
- name: timeoutDockerPublish
displayName: "Timout Docker publish"
type: number
default: 10
- name: timeoutDockerBuild
displayName: "Timout Docker build"
type: number
default: 400
## Build settings
- name: cacheTestResults
displayName: "Cache test results"
type: boolean
default: true
stages:
- stage: env
displayName: Environment
jobs:
- template: env.yml
- stage: prechecks
displayName: Prechecks
dependsOn: ["env"]
jobs:
- template: stage/prechecks.yml
parameters:
concurrencyPrechecks: ${{ parameters.concurrencyPrechecks }}
cacheTestResults: ${{ parameters.cacheTestResults }}
authGCP: $(GcpServiceAccountKey)
authGPGPassphrase: $(MaintainerGPGKeyPassphrase)
authGPGKey: $(MaintainerGPGKeySecureFileDownloadPath)
authGPGPath: $(MaintainerGPGKey.secureFilePath)
bucketGCP: $(GcsArtifactBucket)
runPrechecks: stageDependencies.env.repo.outputs['run.releaseTests']
- stage: linux_x64
displayName: Linux x64
dependsOn: ${{ parameters.buildStageDeps }}
variables:
RUN_BUILD: $[stageDependencies.env.repo.outputs['run.build']]
RUN_TESTS: $[stageDependencies.env.repo.outputs['run.releaseTests']]
jobs:
- template: stage/linux.yml
parameters:
cacheTestResults: ${{ parameters.cacheTestResults }}
bazelConfigRBE: --config=remote-ci --config=rbe-google --jobs=200
pool: envoy-x64-large
# these are parsed differently and _must_ be expressed in this way
runBuild: variables['RUN_BUILD']
runTests: $(RUN_TESTS)
- stage: linux_arm64
displayName: Linux arm64
dependsOn: ${{ parameters.buildStageDeps }}
variables:
RUN_BUILD: $[stageDependencies.env.repo.outputs['run.build']]
RUN_TESTS: $[stageDependencies.env.repo.outputs['run.releaseTests']]
jobs:
- template: stage/linux.yml
parameters:
cacheTestResults: ${{ parameters.cacheTestResults }}
rbe: false
artifactSuffix: .arm64
timeoutBuild: 180
pool: envoy-arm-large
runBuild: variables['RUN_BUILD']
runTests: $(RUN_TESTS)
bazelBuildExtraOptions: "--sandbox_base=/tmp/sandbox_base"
- stage: check
displayName: Checks (Linux x64)
dependsOn: ${{ parameters.checkStageDeps }}
variables:
# Skip checks if only mobile/ or docs/ have changed.
RUN_CHECKS: $[stageDependencies.env.repo.outputs['run.checks']]
jobs:
- template: stage/checks.yml
parameters:
cacheTestResults: ${{ parameters.cacheTestResults }}
concurrencyChecks: ${{ parameters.concurrencyChecks }}
authGCP: $(GcpServiceAccountKey)
bucketGCP: $(GcsArtifactBucket)
runChecks: variables['RUN_CHECKS']
- stage: publish
displayName: Publish
dependsOn: ["env", "linux_x64", "linux_arm64"]
variables:
RUN_DOCKER: $[stageDependencies.env.repo.outputs['run.docker']]
RUN_PACKAGING: $[stageDependencies.env.repo.outputs['run.packaging']]
PUBLISH_GITHUB_RELEASE: $[stageDependencies.env.repo.outputs['publish.githubRelease']]
PUBLISH_DOCKERHUB: $[stageDependencies.env.repo.outputs['publish.dockerhub']]
jobs:
- template: stage/publish.yml
parameters:
authDockerUser: $(DockerUsername)
authDockerPassword: $(DockerPassword)
authGCP: $(GcpServiceAccountKey)
authGithubWorkflow: $(GitHubPublicRepoWorkflowKey)
authGithubWorkflowAppId: $(GitHubPublicRepoWorkflowAppId)
authGithubWorkflowInstallId: $(GitHubPublicRepoWorkflowInstallId)
authGPGPassphrase: $(MaintainerGPGKeyPassphrase)
authGPGKey: $(MaintainerGPGKeySecureFileDownloadPath)
authGPGPath: $(MaintainerGPGKey.secureFilePath)
bucketGCP: $(GcsArtifactBucket)
timeoutDockerBuild: ${{ parameters.timeoutDockerBuild }}
timeoutDockerPublish: ${{ parameters.timeoutDockerPublish }}
runDocker: variables['RUN_DOCKER']
runPackaging: variables['RUN_PACKAGING']
publishDockerhub: variables['PUBLISH_DOCKERHUB']
publishGithubRelease: variables['PUBLISH_GITHUB_RELEASE']
- stage: verify
displayName: Verify
dependsOn: ["env", "publish"]
variables:
RUN_DOCKER: $[stageDependencies.env.repo.outputs['run.docker']]
jobs:
- template: stage/verify.yml
parameters:
authGCP: $(GcpServiceAccountKey)