forked from ipasimulator/ipasim
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.azure-ci.yml
60 lines (58 loc) · 1.81 KB
/
.azure-ci.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
# For more information, see `/scripts/ci/README.md`.
# Here are variables you have to set, so that this build can function:
#
# `docker.password` ...password to Docker repository `ipasim`.
# `azure.key`, `azure.app.id`, `azure.tenant` ...see `/scripts/ci/README.md` for
# more details.
# `azure.subscription.id` ...ID of the subscription the VM is located in.
#
# Here are variables you can configure the build with along with values you can
# set for them:
#
# `pull.docker.image`: 1 ...pulls the Docker image instead of building it.
# `pull.build.artifacts`: 1 ...pulls Docker image containing build artifacts,
# effectively doing an incremental build.
# `shutdown.when.complete`: 1 ...shutdowns the computer in the end.
# `reset.repository`: 1 ...removes and then clones sources from scratch
# (otherwise, if the repo already exists locally, it's only incrementally
# updated to the latest version).
# `build.tablegens.only`: 1 ...runs only a sample build command (bulding just
# tablegens). This can be used to test incremental building (see also #14).
#
# Note that these variables are converted to uppercase and have dots replaced
# with underscores before being visible as environment variables in batch
# scripts.
resources:
- repo: self
fetchDepth: 1
clean: true
lfs: true
trigger:
batch: true
branches:
include:
- master
jobs:
- job: StartVM
pool: Hosted VS2017
steps:
- powershell: ./scripts/ci/start.ps1
env:
AZURE_KEY: $(azure.key)
- job: Build
dependsOn: StartVM
pool: Default
steps:
- script: ./scripts/ci/build.cmd
env:
GIT_TOKEN: $(git.token)
DOCKER_PASSWORD: $(docker.password)
timeoutInMinutes: 0
- job: StopVM
dependsOn: Build
condition: succeededOrFailed()
pool: Hosted VS2017
steps:
- powershell: ./scripts/ci/stop.ps1
env:
AZURE_KEY: $(azure.key)