Push package info to maestro
This commit is contained in:
Родитель
f9456f9ac3
Коммит
5a72e3a14c
|
@ -203,6 +203,45 @@ stages:
|
|||
displayName: Sign Phase
|
||||
condition: and(succeeded(), ${{ variables['signingCondition'] }} )
|
||||
|
||||
- job: push_signed_nugets
|
||||
displayName: Push To Maestro
|
||||
dependsOn: signing
|
||||
condition: eq(dependencies.signing.result, 'Succeeded')
|
||||
timeoutInMinutes: 60
|
||||
pool: VSEngSS-MicroBuild2022-1ES
|
||||
workspace:
|
||||
clean: all
|
||||
variables:
|
||||
- group: Publish-Build-Assets
|
||||
steps:
|
||||
- checkout: self
|
||||
|
||||
- task: DownloadPipelineArtifact@2
|
||||
displayName: Download Signed Packages
|
||||
inputs:
|
||||
artifactName: nuget
|
||||
downloadPath: $(Build.StagingDirectory)\nuget-signed
|
||||
patterns: |
|
||||
**/signed/*.nupkg
|
||||
|
||||
- powershell: >-
|
||||
& dotnet build -v:n
|
||||
-t:PushManifestToBuildAssetRegistry
|
||||
-p:BuildAssetRegistryToken=$(MaestroAccessToken)
|
||||
-p:OutputPath=$(Build.StagingDirectory)\nuget-signed\
|
||||
$(System.DefaultWorkingDirectory)\build\DotNet\Dependencies\Workloads.csproj
|
||||
displayName: generate and publish BAR manifest
|
||||
condition: and(succeeded(), eq(variables['PushPackageInfoToMaestro'], 'true'))
|
||||
|
||||
- powershell: |
|
||||
$versionEndpoint = 'https://maestro-prod.westus2.cloudapp.azure.com/api/assets/darc-version?api-version=2019-01-16'
|
||||
$darcVersion = $(Invoke-WebRequest -Uri $versionEndpoint -UseBasicParsing).Content
|
||||
$arcadeServicesSource = 'https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet-eng/nuget/v3/index.json'
|
||||
& dotnet tool update microsoft.dotnet.darc --version "$darcVersion" --add-source "$arcadeServicesSource" --tool-path $(Agent.ToolsDirectory)\darc -v n
|
||||
& $(Agent.ToolsDirectory)\darc\darc add-build-to-channel --default-channels --id $(BARBuildId) --publishing-infra-version 3 --skip-assets-publishing --password $(MaestroAccessToken) --azdev-pat $(publishing-dnceng-devdiv-code-r-build-re)
|
||||
displayName: add build to default darc channel
|
||||
condition: and(succeeded(), eq(variables['PushPackageInfoToMaestro'], 'true'))
|
||||
|
||||
- stage: sbom
|
||||
displayName: 'Software Bill of Materials'
|
||||
dependsOn: [ 'windows', 'nuget_signing' ]
|
||||
|
|
|
@ -1 +1,52 @@
|
|||
<Project />
|
||||
<Project>
|
||||
<PropertyGroup>
|
||||
<_RepositoryPath>$(MSBuildThisFileDirectory)../../../</_RepositoryPath>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Microsoft.DotNet.Build.Tasks.Feed" Version="$(MicrosoftDotNetBuildTasksFeedPackageVersion)" PrivateAssets="all" />
|
||||
<PackageReference Include="Microsoft.DotNet.Arcade.Sdk" Version="$(MicrosoftDotNetBuildTasksFeedPackageVersion)" PrivateAssets="all" GeneratePathProperty="true" />
|
||||
</ItemGroup>
|
||||
|
||||
<Import Project="Sdk.props" Sdk="Microsoft.DotNet.SharedFramework.Sdk" Version="$(MicrosoftDotNetBuildTasksFeedPackageVersion)" />
|
||||
<UsingTask TaskName="GenerateBuildManifest" AssemblyFile="$(_MicrosoftDotNetBuildTasksFeedTaskDir)Microsoft.DotNet.Build.Tasks.Feed.dll" />
|
||||
|
||||
<Target Name="PushManifestToBuildAssetRegistry" >
|
||||
<ItemGroup>
|
||||
<BuildArtifacts Include="$(OutputPath)*.nupkg" />
|
||||
</ItemGroup>
|
||||
|
||||
<Error Condition="'@(BuildArtifacts)' == ''" Text="No packages to create manifest from." />
|
||||
|
||||
<ItemGroup>
|
||||
<ManifestBuildData Include="InitialAssetsLocation=https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet6/nuget/v3/index.json" />
|
||||
<ManifestBuildData Include="AzureDevOpsBuildId=$(BUILD_BUILDID)" />
|
||||
<ManifestBuildData Include="AzureDevOpsBuildDefinitionId=$(SYSTEM_DEFINITIONID)" />
|
||||
<ManifestBuildData Include="AzureDevOpsProject=$(SYSTEM_TEAMPROJECT)" />
|
||||
<ManifestBuildData Include="AzureDevOpsBuildNumber=$(BUILD_BUILDNUMBER)" />
|
||||
<ManifestBuildData Include="AzureDevOpsRepository=$(BUILD_REPOSITORY_URI)" />
|
||||
<ManifestBuildData Include="AzureDevOpsBranch=$(BUILD_SOURCEBRANCH)" />
|
||||
</ItemGroup>
|
||||
|
||||
<GenerateBuildManifest
|
||||
Artifacts="@(BuildArtifacts)"
|
||||
OutputPath="$(OutputPath)bar-manifests\AssetManifest.xml"
|
||||
BuildId="$(BUILD_BUILDNUMBER)"
|
||||
BuildData="@(ManifestBuildData)"
|
||||
RepoUri="$(BUILD_REPOSITORY_URI)"
|
||||
RepoBranch="$(BUILD_SOURCEBRANCH)"
|
||||
RepoCommit="$(BUILD_SOURCEVERSION)"
|
||||
PublishingVersion="3" />
|
||||
|
||||
<MSBuild
|
||||
Targets="Restore"
|
||||
Projects="$(PkgMicrosoft_DotNet_Arcade_Sdk)\tools\SdkTasks\PublishBuildAssets.proj"
|
||||
Properties="Configuration=$(Configuration);RepoRoot=$(_RepositoryPath);VersionPrefix=$(PackageVersion)"
|
||||
/>
|
||||
|
||||
<MSBuild
|
||||
Projects="$(PkgMicrosoft_DotNet_Arcade_Sdk)\tools\SdkTasks\PublishBuildAssets.proj"
|
||||
Properties="Configuration=$(Configuration);RepoRoot=$(_RepositoryPath);VersionPrefix=$(PackageVersion);ManifestsPath=$(OutputPath)bar-manifests;MaestroApiEndpoint=https://maestro-prod.westus2.cloudapp.azure.com"
|
||||
/>
|
||||
</Target>
|
||||
</Project>
|
||||
|
|
|
@ -28,9 +28,15 @@
|
|||
<Uri>https://github.com/xamarin/xamarin-macios</Uri>
|
||||
<Sha>aa3d95ef22985c6e5bfaa80da558acda89a8967d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.NET.Workload.Emscripten.Manifest-6.0.300" Version="6.0.4" CoherentParentDependency="Microsoft.NETCore.App.Ref">
|
||||
<Dependency Name="Microsoft.NET.Workload.Emscripten.Manifest-6.0.300" Version="6.0.4" CoherentParentDependency="Microsoft.NETCore.App.Ref">
|
||||
<Uri>https://github.com/dotnet/emsdk</Uri>
|
||||
<Sha>572aeedcfa16bdb619fafcecf5924e5c6b65b07b</Sha>
|
||||
</Dependency>
|
||||
</ProductDependencies>
|
||||
<ToolsetDependencies>
|
||||
<Dependency Name="Microsoft.DotNet.Build.Tasks.Feed" Version="7.0.0-beta.22171.2">
|
||||
<Uri>https://github.com/dotnet/arcade</Uri>
|
||||
<Sha>c8a95297e2622251c125aa5c0ef7c822275a792d</Sha>
|
||||
</Dependency>
|
||||
</ToolsetDependencies>
|
||||
</Dependencies>
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
<MicrosoftMacCatalystSdkPackageVersion>15.4.100-rc.1.69</MicrosoftMacCatalystSdkPackageVersion>
|
||||
<MicrosoftmacOSSdkPackageVersion>12.3.100-rc.1.69</MicrosoftmacOSSdkPackageVersion>
|
||||
<MicrosofttvOSSdkPackageVersion>15.4.100-rc.1.69</MicrosofttvOSSdkPackageVersion>
|
||||
<MicrosoftDotNetBuildTasksFeedPackageVersion>7.0.0-beta.22171.2</MicrosoftDotNetBuildTasksFeedPackageVersion>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<DotNetVersionBand Condition=" '$(DotNetVersionBand)' == '' ">6.0.300</DotNetVersionBand>
|
||||
|
|
Загрузка…
Ссылка в новой задаче