1
+ jobs :
2
+ - job : BuildCoreToolsHostWindows
3
+ displayName : ' [Windows] Build CoreToolsHost'
4
+ pool :
5
+ name : 1es-pool-azfunc
6
+ image : 1es-windows-2022
7
+ os : windows
8
+
9
+ steps :
10
+ - task : UseDotNet@2
11
+ inputs :
12
+ version : 9.x
13
+ includePreviewVersions : true
14
+ displayName : Install .NET 9
15
+ - task : UseDotNet@2
16
+ inputs :
17
+ version : 6.x
18
+ displayName : Install .NET 6
19
+
20
+ - task : DotnetCoreCLI@2
21
+ displayName : Dotnet Publish (win-x64)
22
+ inputs :
23
+ command : publish
24
+ publishWebProjects : false
25
+ zipAfterPublish : false
26
+ arguments : -c Release -r win-x64 -o $(Build.SourcesDirectory)/pkg_output/windows/win-x64 --self-contained
27
+ workingDirectory : $(Build.SourcesDirectory)/host/src/CoreToolsHost
28
+
29
+ - task : DotnetCoreCLI@2
30
+ displayName : Dotnet Publish (win-arm64)
31
+ inputs :
32
+ command : publish
33
+ publishWebProjects : false
34
+ zipAfterPublish : false
35
+ arguments : -c Release -r win-arm64 -o $(Build.SourcesDirectory)/pkg_output/windows/win-arm64 --self-contained
36
+ workingDirectory : $(Build.SourcesDirectory)/host/src/CoreToolsHost
37
+
38
+ - template : ci/sign-files.yml@eng
39
+ parameters :
40
+ displayName : ' Authenticode signing (dll) (win-arm64)'
41
+ folderPath : ' $(Build.SourcesDirectory)/pkg_output/windows/win-arm64'
42
+ pattern : ' *.dll, *.exe'
43
+ signType : inline
44
+ inlineOperation : |
45
+ [
46
+ {
47
+ "KeyCode": "CP-230012",
48
+ "OperationCode": "SigntoolSign",
49
+ "Parameters": {
50
+ "OpusName": "Microsoft",
51
+ "OpusInfo": "http://www.microsoft.com",
52
+ "FileDigest": "/fd \"SHA256\"",
53
+ "PageHash": "/NPH",
54
+ "TimeStamp": "/tr \"http://rfc3161.gtm.corp.microsoft.com/TSS/HttpTspServer\" /td sha256"
55
+ },
56
+ "ToolName": "sign",
57
+ "ToolVersion": "1.0"
58
+ },
59
+ {
60
+ "KeyCode": "CP-230012",
61
+ "OperationCode": "SigntoolVerify",
62
+ "Parameters": {},
63
+ "ToolName": "sign",
64
+ "ToolVersion": "1.0"
65
+ }
66
+ ]
67
+
68
+ - template : ci/sign-files.yml@eng
69
+ parameters :
70
+ displayName : ' Authenticode signing (dll) (win-x64)'
71
+ folderPath : ' $(Build.SourcesDirectory)/pkg_output/windows/win-x64'
72
+ pattern : ' *.dll, *.exe'
73
+ signType : inline
74
+ inlineOperation : |
75
+ [
76
+ {
77
+ "KeyCode": "CP-230012",
78
+ "OperationCode": "SigntoolSign",
79
+ "Parameters": {
80
+ "OpusName": "Microsoft",
81
+ "OpusInfo": "http://www.microsoft.com",
82
+ "FileDigest": "/fd \"SHA256\"",
83
+ "PageHash": "/NPH",
84
+ "TimeStamp": "/tr \"http://rfc3161.gtm.corp.microsoft.com/TSS/HttpTspServer\" /td sha256"
85
+ },
86
+ "ToolName": "sign",
87
+ "ToolVersion": "1.0"
88
+ },
89
+ {
90
+ "KeyCode": "CP-230012",
91
+ "OperationCode": "SigntoolVerify",
92
+ "Parameters": {},
93
+ "ToolName": "sign",
94
+ "ToolVersion": "1.0"
95
+ }
96
+ ]
97
+
98
+ - task : CopyFiles@2
99
+ displayName : Copy files (win-x64)
100
+ inputs :
101
+ SourceFolder : $(Build.SourcesDirectory)/pkg_output/windows/win-x64
102
+ # Publish output will include many other files. We only need func.exe & nethost.dll
103
+ Contents : |
104
+ func.exe
105
+ nethost.dll
106
+ TargetFolder : $(Build.ArtifactStagingDirectory)/_coreToolsHostPackagesWindows/win-x64
107
+
108
+ - task : CopyFiles@2
109
+ displayName : Copy files (win-arm64)
110
+ inputs :
111
+ SourceFolder : $(Build.SourcesDirectory)/pkg_output/windows/win-arm64
112
+ # Publish output will include many other files. We only need func.exe & nethost.dll
113
+ Contents : |
114
+ func.exe
115
+ nethost.dll
116
+ TargetFolder : $(Build.ArtifactStagingDirectory)/_coreToolsHostPackagesWindows/win-arm64
117
+
118
+ templateContext :
119
+ outputParentDirectory : $(Build.ArtifactStagingDirectory)
120
+ outputs :
121
+ - output : pipelineArtifact
122
+ path : $(Build.ArtifactStagingDirectory)/_coreToolsHostPackagesWindows
123
+ artifact : drop-coretools-host-windows
0 commit comments