forked from microsoft/CCF
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.azure-pipelines-quictls.yml
61 lines (53 loc) · 1.94 KB
/
.azure-pipelines-quictls.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
trigger:
batch: false
parameters:
- name: VERSION
displayName: QUICTLS version
type: string
default: "1.1.1"
- name: REV
displayName: QUICTLS version revision
type: string
default: "o"
- name: PUSH_ARTIFACT
displayName: Publish to package feed
type: boolean
default: true
jobs:
- job: build_quictls
container: ccfmsrc.azurecr.io/ccf/ci:27-04-2023-virtual
pool: 1es-dv4-focal
strategy:
matrix:
debug:
MODE: "debug"
release:
MODE: "release"
steps:
- checkout: self
clean: true
- script: scripts/quictls/build.sh ${{ parameters.VERSION }} ${{ parameters.REV }} $(MODE) ${{ parameters.PUSH_ARTIFACT }}
displayName: "Build QUICTLS"
- ${{ if eq(parameters.PUSH_ARTIFACT, true) }}:
- script: |
# Version to MAJOR
VERSION=${{ parameters.VERSION }}
MAJOR=${VERSION//./}
# Rev to MINOR (assuming it doesn't go beyond 'z')
CHAR=$(printf '%d' "'${{ parameters.REV }}'")
BASE=$(printf '%d' "'a'")
MINOR=$(($CHAR-$BASE+1))
# MAJOR.MINOR (BUILD automatic and incrementing)
echo "##vso[task.setvariable variable=pkg-ver]$MAJOR.$MINOR.$(Build.BuildId)"
mv scripts/quictls/quictls-${{ parameters.VERSION }}${{ parameters.REV }}-$(MODE).tar.xz $(Build.ArtifactStagingDirectory)
displayName: "Prepare Artifact Staging Directory"
- task: UniversalPackages@0
displayName: "Publish QUICTLS Artifact"
inputs:
command: publish
publishDirectory: "$(Build.ArtifactStagingDirectory)"
vstsFeedPublish: "CCF/QUICTLS"
vstsFeedPackagePublish: "quictls-$(MODE)"
versionOption: custom
versionPublish: "$(pkg-ver)"
packagePublishDescription: "CCF build of QUICTLS-enabled OpenSSL"