Update yaml build pipeline to use IISCommon build templates
This commit is contained in:
Родитель
561638909c
Коммит
3b9fd86b57
|
@ -0,0 +1,3 @@
|
|||
[submodule "IIS.Common"]
|
||||
path = IIS.Common
|
||||
url = https://github.com/Microsoft/IIS.Common.git
|
|
@ -1,12 +1,31 @@
|
|||
name: $(Rev:rr)
|
||||
name: $(SourceBranchName)_$(Date:yyyyMMdd)$(Rev:.rr)
|
||||
|
||||
pr:
|
||||
- master
|
||||
|
||||
trigger:
|
||||
batch: true
|
||||
branches:
|
||||
include:
|
||||
- master
|
||||
|
||||
resources:
|
||||
repositories:
|
||||
- repository: MicrosoftIISCommon
|
||||
type: github
|
||||
name: Microsoft/IIS.Common
|
||||
endpoint: GitHub-IIS-PAT
|
||||
|
||||
jobs:
|
||||
- template: templates\build.yml
|
||||
- template: .azure\templates\build.yml@MicrosoftIISCommon
|
||||
parameters:
|
||||
agentPoolName: 'VSEng-MicroBuildV2CustomPool'
|
||||
agentPoolDemandTeam: 'IISAdmin'
|
||||
agentPoolName: 'VSEng-MicroBuildVS2017'
|
||||
agentPoolDemandTeam: ''
|
||||
solution: '**\ServiceMonitor.sln'
|
||||
productMajor: 2
|
||||
productMinor: 0
|
||||
signType: 'test'
|
||||
publishArtifactInstaller: 'false'
|
||||
indexSourcesAndPublishSymbols: 'true'
|
||||
publishArtifactInstallers: 'false'
|
||||
whiteListPathForAuthenticodeSign: '$(Build.SourcesDirectory)\IIS-Common\.azure\templates\no_authenticode.txt'
|
||||
|
||||
|
|
|
@ -1,13 +1,24 @@
|
|||
name: $(Rev:rr)
|
||||
name: $(SourceBranchName)_$(Date:yyyyMMdd)$(Rev:.rr)
|
||||
|
||||
pr: none
|
||||
trigger: none
|
||||
|
||||
resources:
|
||||
repositories:
|
||||
- repository: MicrosoftIISCommon
|
||||
type: github
|
||||
name: Microsoft/IIS.Common
|
||||
endpoint: GitHub-IIS-PAT
|
||||
|
||||
jobs:
|
||||
- template: templates\build.yml
|
||||
- template: .azure\templates\build.yml@MicrosoftIISCommon
|
||||
parameters:
|
||||
agentPoolName: 'VSEng-MicroBuildV2CustomPool'
|
||||
agentPoolDemandTeam: 'IISAdmin'
|
||||
agentPoolName: 'VSEng-MicroBuildVS2017'
|
||||
agentPoolDemandTeam: ''
|
||||
solution: '**\ServiceMonitor.sln'
|
||||
productMajor: 1
|
||||
productMinor: 0
|
||||
signType: 'real'
|
||||
indexSourcesAndPublishSymbols: 'true'
|
||||
publishArtifactInstaller: 'false'
|
||||
publishArtifactInstallers: 'false'
|
||||
whiteListPathForAuthenticodeSign: '$(Build.SourcesDirectory)\IIS-Common\.azure\templates\no_authenticode.txt'
|
||||
|
|
|
@ -1,149 +0,0 @@
|
|||
parameters:
|
||||
agentPoolName: ''
|
||||
agentPoolDemandTeam: ''
|
||||
solution: '**\*.sln'
|
||||
buildConfiguration: 'Release'
|
||||
productMajor: 1
|
||||
productMinor: 0
|
||||
signType: 'test'
|
||||
signingIdentity: 'Microsoft'
|
||||
teamName: 'IIS'
|
||||
indexSourcesAndPublishSymbols: 'false'
|
||||
publishArtifactInstaller: 'false'
|
||||
|
||||
jobs:
|
||||
- job: build
|
||||
|
||||
pool:
|
||||
name: ${{ parameters.agentPoolName }}
|
||||
demands:
|
||||
- msbuild
|
||||
- visualstudio
|
||||
- ${{ if ne(parameters.agentPoolDemandTeam, '') }}:
|
||||
- Team -equals ${{ parameters.agentPoolDemandTeam }}
|
||||
|
||||
variables:
|
||||
TeamName: ${{ parameters.teamName }} # required by MicroBuildTasks
|
||||
|
||||
steps:
|
||||
- checkout: self
|
||||
clean: true
|
||||
submodules: recursive
|
||||
|
||||
- task: ms-vseng.MicroBuildTasks.30666190-6959-11e5-9f96-f56098202fef.MicroBuildSigningPlugin@1
|
||||
displayName: 'Install Signing Plugin'
|
||||
inputs:
|
||||
signType: ${{ parameters.signType }}
|
||||
|
||||
- task: NuGetToolInstaller@1
|
||||
displayName: 'Install NuGet Tool'
|
||||
inputs:
|
||||
versionSpec: '>=4.7.1'
|
||||
|
||||
- task: NuGetCommand@2
|
||||
displayName: 'NuGet restore'
|
||||
inputs:
|
||||
command: 'restore'
|
||||
restoreSolution: ${{ parameters.solution }}
|
||||
feedsToUse: config
|
||||
nugetConfigPath: NuGet.config
|
||||
|
||||
- task: ms.vss-governance-buildtask.governance-build-task-component-detection.ComponentGovernanceComponentDetection@0
|
||||
displayName: 'Component Detection'
|
||||
|
||||
- task: VSBuild@1
|
||||
displayName: 'Build x86'
|
||||
inputs:
|
||||
solution: ${{ parameters.solution }}
|
||||
vsVersion: 15.0
|
||||
msbuildArgs: '/p:PRODUCT_MAJOR=${{ parameters.productMajor }} /p:PRODUCT_MINOR=${{ parameters.productMinor }} /p:BUILD_MAJOR=$(Build.BuildNumber) /p:SignType=${{ parameters.signType }} /p:SigningIdentity=${{ parameters.signingIdentity }}'
|
||||
platform: x86
|
||||
configuration: ${{ parameters.buildConfiguration }}
|
||||
clean: true
|
||||
msbuildArchitecture: x64
|
||||
|
||||
- task: VSBuild@1
|
||||
displayName: 'Build x64'
|
||||
inputs:
|
||||
solution: ${{ parameters.solution }}
|
||||
vsVersion: 15.0
|
||||
msbuildArgs: '/p:PRODUCT_MAJOR=${{ parameters.productMajor }} /p:PRODUCT_MINOR=${{ parameters.productMinor }} /p:BUILD_MAJOR=$(Build.BuildNumber) /p:SignType=${{ parameters.signType }} /p:SigningIdentity=${{ parameters.signingIdentity }}'
|
||||
platform: x64
|
||||
configuration: ${{ parameters.buildConfiguration }}
|
||||
clean: true
|
||||
msbuildArchitecture: x64
|
||||
|
||||
- task: CopyFiles@2
|
||||
displayName: 'Copy Binaries x86'
|
||||
inputs:
|
||||
SourceFolder: '$(Build.SourcesDirectory)\bin\${{ parameters.buildConfiguration }}\x86'
|
||||
Contents: |
|
||||
**\*.dll
|
||||
**\*.exe
|
||||
TargetFolder: '$(Build.ArtifactStagingDirectory)\Binaries\x86'
|
||||
|
||||
- task: CopyFiles@2
|
||||
displayName: 'Copy Binaries x64'
|
||||
inputs:
|
||||
SourceFolder: '$(Build.SourcesDirectory)\bin\${{ parameters.buildConfiguration }}\x64'
|
||||
Contents: |
|
||||
**\*.dll
|
||||
**\*.exe
|
||||
TargetFolder: '$(Build.ArtifactStagingDirectory)\Binaries\x64'
|
||||
|
||||
- task: CopyFiles@2
|
||||
displayName: 'Copy Symbols x86'
|
||||
inputs:
|
||||
SourceFolder: '$(Build.SourcesDirectory)'
|
||||
Contents: '**\x86\**\*.pdb'
|
||||
TargetFolder: '$(Build.ArtifactStagingDirectory)\Symbols\x86'
|
||||
|
||||
- task: CopyFiles@2
|
||||
displayName: 'Copy Symbols x64'
|
||||
inputs:
|
||||
SourceFolder: '$(Build.SourcesDirectory)'
|
||||
Contents: '**\x64\**\*pdb'
|
||||
TargetFolder: '$(Build.ArtifactStagingDirectory)\Symbols\x64'
|
||||
|
||||
- ${{ if eq(parameters.publishArtifactInstaller, 'true') }}:
|
||||
- task: CopyFiles@2
|
||||
displayName: 'Copy Installers x86'
|
||||
inputs:
|
||||
SourceFolder: '$(Build.SourcesDirectory)\bin\${{ parameters.buildConfiguration }}\x86'
|
||||
Contents: '**\*.msi'
|
||||
TargetFolder: '$(Build.ArtifactStagingDirectory)\Installers\x86'
|
||||
|
||||
- ${{ if eq(parameters.publishArtifactInstaller, 'true') }}:
|
||||
- task: CopyFiles@2
|
||||
displayName: 'Copy Installers x64'
|
||||
inputs:
|
||||
SourceFolder: '$(Build.SourcesDirectory)\bin\${{ parameters.buildConfiguration }}\x64'
|
||||
Contents: '**\*.msi'
|
||||
TargetFolder: '$(Build.ArtifactStagingDirectory)\Installers\x64'
|
||||
|
||||
- ${{ if eq(parameters.indexSourcesAndPublishSymbols, 'true') }}:
|
||||
- task: PublishSymbols@2
|
||||
displayName: 'Enable Source Server'
|
||||
inputs:
|
||||
SymbolsFolder: '$(Build.ArtifactStagingDirectory)\Symbols'
|
||||
SearchPattern: '**\*.pdb'
|
||||
SymbolServerType: TeamServices
|
||||
|
||||
- task: PublishBuildArtifacts@1
|
||||
displayName: 'Publish Artifact: Binaries'
|
||||
inputs:
|
||||
PathtoPublish: '$(Build.ArtifactStagingDirectory)\Binaries'
|
||||
ArtifactName: Binaries
|
||||
|
||||
- task: PublishBuildArtifacts@1
|
||||
displayName: 'Publish Artifact: Symbols'
|
||||
inputs:
|
||||
PathtoPublish: '$(Build.ArtifactStagingDirectory)\Symbols'
|
||||
ArtifactName: Symbols
|
||||
|
||||
- ${{ if eq(parameters.publishArtifactInstaller, 'true') }}:
|
||||
- task: PublishBuildArtifacts@1
|
||||
displayName: 'Publish Artifact: Installers'
|
||||
inputs:
|
||||
PathtoPublish: '$(Build.ArtifactStagingDirectory)\Installers'
|
||||
ArtifactName: Installers
|
|
@ -0,0 +1,13 @@
|
|||
<!--
|
||||
****************************************************************************************************
|
||||
Directory.Build.props file.
|
||||
This file is imported automatically by Microsoft.Common.props very early in the build process.
|
||||
|
||||
This file should be placed at the repository root.
|
||||
****************************************************************************************************
|
||||
-->
|
||||
|
||||
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<!-- <Import Project="root.props" Condition="Exists('root.props')" /> -->
|
||||
<Import Project="root.props" />
|
||||
</Project>
|
|
@ -0,0 +1 @@
|
|||
Subproject commit dae947dd67c25fa0974c3a7b6975c615511c18a9
|
|
@ -1,6 +1,6 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<configuration>
|
||||
<config>
|
||||
<add key="repositoryPath" value="%userprofile%\.nuget\GlobalPackages" />
|
||||
<add key="repositoryPath" value="packages" />
|
||||
</config>
|
||||
</configuration>
|
|
@ -0,0 +1,6 @@
|
|||
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<PlatformShortname Condition="'$(PlatformShortname)' == '' AND '$(Platform)' == 'x64'">x64</PlatformShortname>
|
||||
<PlatformShortname Condition="'$(PlatformShortname)' == '' AND ('$(Platform.ToLower())' == 'win32' OR '$(Platform)' == 'x86')">x86</PlatformShortname>
|
||||
</PropertyGroup>
|
||||
</Project>
|
|
@ -0,0 +1,13 @@
|
|||
<!--
|
||||
****************************************************************************************************
|
||||
Project global versioning targets.
|
||||
****************************************************************************************************-->
|
||||
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
|
||||
<PropertyGroup>
|
||||
<RepositoryRoot>$(MSBuildThisFileDirectory)</RepositoryRoot>
|
||||
<SourceRoot>$(RepositoryRoot)src</SourceRoot>
|
||||
</PropertyGroup>
|
||||
|
||||
<Import Project="$(RepositoryRoot)build\Build.Settings.targets" Condition="Exists('$(RepositoryRoot)build\Build.Settings.targets')" />
|
||||
</Project>
|
|
@ -1,11 +1,6 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<Import Project="..\..\packages\MicroBuild.Core.0.2.0\build\MicroBuild.Core.props" Condition="Exists('..\..\packages\MicroBuild.Core.0.2.0\build\MicroBuild.Core.props')" />
|
||||
<ItemGroup Condition=" '$(SignType)' != ''">
|
||||
<FilesToSign Include="$(FilesToSign);$(OutDir)\$(TargetFileName)">
|
||||
<Authenticode>$(SigningIdentity)</Authenticode>
|
||||
</FilesToSign>
|
||||
</ItemGroup>
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<Configuration>Debug</Configuration>
|
||||
|
@ -31,6 +26,10 @@
|
|||
<WindowsTargetPlatformVersion>10.0.15063.0</WindowsTargetPlatformVersion>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup>
|
||||
<OutDir>$(RepositoryRoot)bin\$(Configuration)\$(PlatformShortname)\</OutDir>
|
||||
<IntDir>$(RepositoryRoot)obj\$(PlatformShortname)\$(Configuration)\$(MSBuildThisFileName)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
|
@ -177,6 +176,11 @@
|
|||
<None Include="packages.config" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ItemGroup Condition=" '$(SignType)' != ''">
|
||||
<FilesToSign Include="$(FilesToSign);$(OutDir)\$(TargetFileName)">
|
||||
<Authenticode>$(SigningIdentity)</Authenticode>
|
||||
</FilesToSign>
|
||||
</ItemGroup>
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
<Import Project="..\..\packages\MicroBuild.Core.0.2.0\build\MicroBuild.Core.targets" Condition="Exists('..\..\packages\MicroBuild.Core.0.2.0\build\MicroBuild.Core.targets')" />
|
||||
</ImportGroup>
|
||||
|
|
Загрузка…
Ссылка в новой задаче