Skip to content

Commit

Permalink
Rollout/2024 07 18 (#3733)
Browse files Browse the repository at this point in the history
  • Loading branch information
dkurepa authored Jul 18, 2024
2 parents 1a74ad9 + 47e3672 commit 8cf1ddb
Show file tree
Hide file tree
Showing 24 changed files with 376 additions and 59 deletions.
1 change: 1 addition & 0 deletions Directory.Packages.props
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,7 @@
<PackageVersion Include="System.Drawing.Common" Version="7.0.0" />
<PackageVersion Include="System.IO.Hashing" Version="8.0.0" />
<PackageVersion Include="System.Linq.Async" Version="6.0.1" />
<PackageVersion Include="System.Formats.Asn1" Version="8.0.1" />
<PackageVersion Include="System.Net.Http" Version="4.3.4" />
<!-- Pin of a transitive dependency. Can be removed after we migrate to net7.0+
https://dnceng.visualstudio.com/internal/_workitems/edit/5117 -->
Expand Down
24 changes: 12 additions & 12 deletions eng/Version.Details.xml
Original file line number Diff line number Diff line change
Expand Up @@ -91,29 +91,29 @@
</Dependency>
</ProductDependencies>
<ToolsetDependencies>
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="8.0.0-beta.24352.1">
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="8.0.0-beta.24360.5">
<Uri>https://github.com/dotnet/arcade</Uri>
<Sha>8b879da4e449c48d99f3f642fc429379a64e8fe8</Sha>
<Sha>c9efa535175049eb9cba06cae1f8c3d5dbe768a9</Sha>
</Dependency>
<Dependency Name="Microsoft.DotNet.SignTool" Version="8.0.0-beta.24352.1">
<Dependency Name="Microsoft.DotNet.SignTool" Version="8.0.0-beta.24360.5">
<Uri>https://github.com/dotnet/arcade</Uri>
<Sha>8b879da4e449c48d99f3f642fc429379a64e8fe8</Sha>
<Sha>c9efa535175049eb9cba06cae1f8c3d5dbe768a9</Sha>
</Dependency>
<Dependency Name="Microsoft.DotNet.Build.Tasks.Feed" Version="8.0.0-beta.24352.1">
<Dependency Name="Microsoft.DotNet.Build.Tasks.Feed" Version="8.0.0-beta.24360.5">
<Uri>https://github.com/dotnet/arcade</Uri>
<Sha>8b879da4e449c48d99f3f642fc429379a64e8fe8</Sha>
<Sha>c9efa535175049eb9cba06cae1f8c3d5dbe768a9</Sha>
</Dependency>
<Dependency Name="Microsoft.DotNet.SwaggerGenerator.MSBuild" Version="8.0.0-beta.24352.1">
<Dependency Name="Microsoft.DotNet.SwaggerGenerator.MSBuild" Version="8.0.0-beta.24360.5">
<Uri>https://github.com/dotnet/arcade</Uri>
<Sha>8b879da4e449c48d99f3f642fc429379a64e8fe8</Sha>
<Sha>c9efa535175049eb9cba06cae1f8c3d5dbe768a9</Sha>
</Dependency>
<Dependency Name="Microsoft.DotNet.Git.IssueManager" Version="8.0.0-beta.24352.1">
<Dependency Name="Microsoft.DotNet.Git.IssueManager" Version="8.0.0-beta.24360.5">
<Uri>https://github.com/dotnet/arcade</Uri>
<Sha>8b879da4e449c48d99f3f642fc429379a64e8fe8</Sha>
<Sha>c9efa535175049eb9cba06cae1f8c3d5dbe768a9</Sha>
</Dependency>
<Dependency Name="Microsoft.DotNet.VersionTools" Version="8.0.0-beta.24352.1">
<Dependency Name="Microsoft.DotNet.VersionTools" Version="8.0.0-beta.24360.5">
<Uri>https://github.com/dotnet/arcade</Uri>
<Sha>8b879da4e449c48d99f3f642fc429379a64e8fe8</Sha>
<Sha>c9efa535175049eb9cba06cae1f8c3d5dbe768a9</Sha>
</Dependency>
<Dependency Name="Microsoft.DncEng.SecretManager" Version="1.1.0-beta.24351.3">
<Uri>https://github.com/dotnet/dnceng</Uri>
Expand Down
10 changes: 5 additions & 5 deletions eng/Versions.props
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@
<UsingToolNetFrameworkReferenceAssemblies>true</UsingToolNetFrameworkReferenceAssemblies>
<MicrosoftNetFrameworkReferenceAssembliesVersion>1.0.0-preview.1</MicrosoftNetFrameworkReferenceAssembliesVersion>
<!-- Libs -->
<MicrosoftDotNetSignToolVersion>8.0.0-beta.24352.1</MicrosoftDotNetSignToolVersion>
<MicrosoftDotNetBuildTasksFeedVersion>8.0.0-beta.24352.1</MicrosoftDotNetBuildTasksFeedVersion>
<MicrosoftDotNetSwaggerGeneratorMSBuildVersion>8.0.0-beta.24352.1</MicrosoftDotNetSwaggerGeneratorMSBuildVersion>
<MicrosoftDotNetGitIssueManagerVersion>8.0.0-beta.24352.1</MicrosoftDotNetGitIssueManagerVersion>
<MicrosoftDotNetVersionToolsVersion>8.0.0-beta.24352.1</MicrosoftDotNetVersionToolsVersion>
<MicrosoftDotNetSignToolVersion>8.0.0-beta.24360.5</MicrosoftDotNetSignToolVersion>
<MicrosoftDotNetBuildTasksFeedVersion>8.0.0-beta.24360.5</MicrosoftDotNetBuildTasksFeedVersion>
<MicrosoftDotNetSwaggerGeneratorMSBuildVersion>8.0.0-beta.24360.5</MicrosoftDotNetSwaggerGeneratorMSBuildVersion>
<MicrosoftDotNetGitIssueManagerVersion>8.0.0-beta.24360.5</MicrosoftDotNetGitIssueManagerVersion>
<MicrosoftDotNetVersionToolsVersion>8.0.0-beta.24360.5</MicrosoftDotNetVersionToolsVersion>
<MicrosoftNetTestSdkVersion>17.4.1</MicrosoftNetTestSdkVersion>
<MicrosoftDotNetInternalLoggingVersion>1.1.0-beta.24359.1</MicrosoftDotNetInternalLoggingVersion>
<MicrosoftAspNetCoreApiPaginationVersion>1.1.0-beta.24359.1</MicrosoftAspNetCoreApiPaginationVersion>
Expand Down
2 changes: 1 addition & 1 deletion eng/common/post-build/publish-using-darc.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ param(
try {
. $PSScriptRoot\post-build-utils.ps1

$darc = Get-Darc "1.1.0-beta.24361.11"
$darc = Get-Darc

$optionalParams = [System.Collections.ArrayList]::new()

Expand Down
9 changes: 6 additions & 3 deletions eng/common/templates-official/job/publish-build-assets.yml
Original file line number Diff line number Diff line change
Expand Up @@ -140,11 +140,14 @@ jobs:
BARBuildId: ${{ parameters.BARBuildId }}
PromoteToChannelIds: ${{ parameters.PromoteToChannelIds }}

- task: PowerShell@2
- task: AzureCLI@2
displayName: Publish Using Darc
inputs:
filePath: $(Build.SourcesDirectory)/eng/common/post-build/publish-using-darc.ps1
arguments: -BuildId $(BARBuildId)
azureSubscription: "Darc: Maestro Production"
scriptType: ps
scriptLocation: scriptPath
scriptPath: $(Build.SourcesDirectory)/eng/common/post-build/publish-using-darc.ps1
arguments: -BuildId $(BARBuildId)
-PublishingInfraVersion 3
-AzdoToken '$(publishing-dnceng-devdiv-code-r-build-re)'
-WaitPublishingFinish true
Expand Down
9 changes: 6 additions & 3 deletions eng/common/templates/job/publish-build-assets.yml
Original file line number Diff line number Diff line change
Expand Up @@ -136,11 +136,14 @@ jobs:
BARBuildId: ${{ parameters.BARBuildId }}
PromoteToChannelIds: ${{ parameters.PromoteToChannelIds }}

- task: PowerShell@2
- task: AzureCLI@2
displayName: Publish Using Darc
inputs:
filePath: $(Build.SourcesDirectory)/eng/common/post-build/publish-using-darc.ps1
arguments: -BuildId $(BARBuildId)
azureSubscription: "Darc: Maestro Production"
scriptType: ps
scriptLocation: scriptPath
scriptPath: $(Build.SourcesDirectory)/eng/common/post-build/publish-using-darc.ps1
arguments: -BuildId $(BARBuildId)
-PublishingInfraVersion 3
-AzdoToken '$(publishing-dnceng-devdiv-code-r-build-re)'
-WaitPublishingFinish true
Expand Down
12 changes: 0 additions & 12 deletions eng/get-darc-version.ps1

This file was deleted.

31 changes: 21 additions & 10 deletions eng/templates/stages/deploy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -203,6 +203,27 @@ stages:
.\darc\darc.exe get-default-channels --source-repo arcade-services --ci -t "$(GetAuthInfo.FederatedToken)" --bar-uri "$(GetAuthInfo.BarUri)" --debug
displayName: Test Federated token authentication

- ${{ if in(variables['Build.SourceBranch'], 'refs/heads/main', 'refs/heads/production') }}:
- task: AzureCLI@2
displayName: Test Darc add-build-to-channel
inputs:
azureSubscription: "Darc: Maestro Production"
scriptType: ps
scriptLocation: inlineScript
inlineScript: |
$darcBuild = .\darc\darc.exe get-build `
--repo "https://github.com/dotnet/arcade-services" `
--commit "$(Build.SourceVersion)" `
--ci `
--output-format json |
ConvertFrom-Json
.\darc\darc.exe add-build-to-channel `
--id $darcBuild[0].id `
--channel "General Testing" `
--ci `
--azdev-pat $(dn-bot-dnceng-build-rw-code-rw-release-rw)
- task: VSTest@2
displayName: Maestro Scenario Tests
inputs:
Expand All @@ -219,13 +240,3 @@ stages:
DARC_PACKAGE_SOURCE: $(Pipeline.Workspace)\PackageArtifacts
DARC_DIR: $(Build.SourcesDirectory)\darc
DARC_IS_CI: true

- powershell: |
nuget sources add -Name "arcade" -Source "https://dotnetfeed.blob.core.windows.net/dotnet-tools-internal/index.json"
nuget sources add -Name "dotnet-core" -Source "https://dotnetfeed.blob.core.windows.net/dotnet-core/index.json"
displayName: Add nuget Sources
- powershell: $(Build.SourcesDirectory)\eng\get-darc-version.ps1
-maestroTestEndpoints "${{ parameters.MaestroTestEndpoints }}"
-apiVersion "2019-01-16"
displayName: Get DARC version
2 changes: 1 addition & 1 deletion global.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,6 @@
}
},
"msbuild-sdks": {
"Microsoft.DotNet.Arcade.Sdk": "8.0.0-beta.24352.1"
"Microsoft.DotNet.Arcade.Sdk": "8.0.0-beta.24360.5"
}
}
2 changes: 2 additions & 0 deletions src/Microsoft.DotNet.Darc/Darc/Operations/Operation.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@

using System;
using System.Threading.Tasks;
using Maestro.Common;
using Maestro.Common.AzureDevOpsTokens;
using Microsoft.Arcade.Common;
using Microsoft.DotNet.Darc.Helpers;
Expand Down Expand Up @@ -76,6 +77,7 @@ protected Operation(ICommandLineOptions options, IServiceCollection? services =
services.TryAddSingleton<IAzureDevOpsClient>(s =>
s.GetRequiredService<AzureDevOpsClient>()
);
services.TryAddSingleton<IRemoteTokenProvider>(_ => new RemoteTokenProvider(options.AzureDevOpsPat, options.GitHubPat));

Provider = services.BuildServiceProvider();
Logger = Provider.GetRequiredService<ILogger<Operation>>();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ protected override async Task ExecuteInternalAsync(
_options.ComponentTemplate,
_options.TpnTemplate,
_options.GenerateCodeowners,
_options.GenerateCredScanSuppressions,
_options.DiscardPatches,
cancellationToken);
}
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ protected override async Task ExecuteInternalAsync(
_options.ComponentTemplate,
_options.TpnTemplate,
_options.GenerateCodeowners,
_options.GenerateCredScanSuppressions,
_options.DiscardPatches,
cancellationToken);
}
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@ internal abstract class VmrSyncCommandLineOptions : VmrCommandLineOptions, IBase
[Option("generate-codeowners", Required = false, HelpText = "Generate a common CODEOWNERS file for all repositories.")]
public bool GenerateCodeowners { get; set; } = false;

[Option("generate-credscansuppressions", Required = false, HelpText = "Generate a common .config/CredScanSuppressions.json file for all repositories.")]
public bool GenerateCredScanSuppressions { get; set; } = false;

[Option("discard-patches", Required = false, HelpText = "Delete .patch files created during the sync.")]
public bool DiscardPatches { get; set; } = false;
}
Loading

0 comments on commit 8cf1ddb

Please sign in to comment.