1
1
parameters :
2
- - name : NpmPublishTag
3
- displayName : ' Tag'
4
- type : string
5
- default : ' legacy'
6
- - name : NpmPublishDryRun
7
- displayName : ' Dry Run'
8
- type : boolean
9
- default : true
2
+ - name : NpmPublishTag
3
+ displayName : ' Tag'
4
+ type : string
5
+ default : ' legacy'
6
+ - name : NpmPublishDryRun
7
+ displayName : ' Dry Run'
8
+ type : boolean
9
+ default : true
10
10
11
11
trigger : none
12
12
pr : none
13
13
14
14
resources :
15
- pipelines :
16
- - pipeline : nodeLibraryCI
17
- project : ' Azure Functions'
18
- source : azure-functions-nodejs-library.build
19
- branch : v3.x
15
+ repositories :
16
+ - repository : 1es
17
+ type : git
18
+ name : 1ESPipelineTemplates/1ESPipelineTemplates
19
+ ref : refs/tags/release
20
+ pipelines :
21
+ - pipeline : officialBuild
22
+ project : internal
23
+ source : nodejs-library.official
24
+ branch : v3.x
20
25
21
- jobs :
22
- - job : Release
23
- pool :
24
- name : ' 1ES-Hosted-AzFunc'
25
- demands :
26
- - ImageOverride -equals MMSUbuntu20.04TLS
27
- steps :
28
- - download : nodeLibraryCI
29
- - task : NodeTool@0
30
- displayName : ' Install Node.js'
31
- inputs :
32
- versionSpec : 14.x
33
- - script : npm ci
34
- displayName : ' npm ci'
35
- - script : ' npm run validateRelease -- --publishTag ${{ parameters.NpmPublishTag }} --dropPath "$(Pipeline.Workspace)/nodeLibraryCI/drop"'
36
- displayName : ' validate release'
37
- - script : mv *.tgz package.tgz
38
- displayName : ' Rename tgz file' # because the publish command below requires an exact path
39
- workingDirectory : ' $(Pipeline.Workspace)/nodeLibraryCI/drop'
40
- - task : Npm@1
41
- displayName : ' npm publish'
42
- inputs :
43
- command : custom
44
- workingDir : ' $(Pipeline.Workspace)/nodeLibraryCI/drop'
45
- verbose : true
46
- customCommand : ' publish package.tgz --tag ${{ parameters.NpmPublishTag }} --dry-run ${{ lower(parameters.NpmPublishDryRun) }}'
47
- customEndpoint : ' Functions Node.js Library Publish'
26
+ extends :
27
+ template : v1/1ES.Official.PipelineTemplate.yml@1es
28
+ parameters :
29
+ sdl :
30
+ sourceAnalysisPool :
31
+ name : 1es-pool-azfunc
32
+ image : 1es-windows-2022
33
+ os : windows
34
+ codeql :
35
+ runSourceLanguagesInSourceAnalysis : true
36
+
37
+ stages :
38
+ - stage : Release
39
+ pool :
40
+ name : 1es-pool-azfunc
41
+ image : 1es-ubuntu-22.04
42
+ os : linux
43
+ jobs :
44
+ - job : Release
45
+ steps :
46
+ - download : officialBuild
47
+ - task : NodeTool@0
48
+ displayName : ' Install Node.js'
49
+ inputs :
50
+ versionSpec : 14.x
51
+ - script : npm ci
52
+ displayName : ' npm ci'
53
+ - script : ' npm run validateRelease -- --publishTag ${{ parameters.NpmPublishTag }} --dropPath "$(Pipeline.Workspace)/officialBuild/drop"'
54
+ displayName : ' validate release'
55
+ - script : mv *.tgz package.tgz
56
+ displayName : ' Rename tgz file' # because the publish command below requires an exact path
57
+ workingDirectory : ' $(Pipeline.Workspace)/officialBuild/drop'
58
+ - task : Npm@1
59
+ displayName : ' npm publish'
60
+ inputs :
61
+ command : custom
62
+ workingDir : ' $(Pipeline.Workspace)/officialBuild/drop'
63
+ verbose : true
64
+ customCommand : ' publish package.tgz --tag ${{ parameters.NpmPublishTag }} --dry-run ${{ lower(parameters.NpmPublishDryRun) }}'
65
+ customEndpoint : nodejs-library-npm
0 commit comments