File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -31,6 +31,19 @@ parameters:
3131 # invoked. Example: ['RNTesterApp-Fabric', 'Playground'].
3232
3333steps :
34+ # The VS Installer's background auto-update service otherwise wakes up mid-build and
35+ # downloads VS updates from the MS CDN, which trips the network isolation policy.
36+ # Follow-up: bake this into the agent image so it doesn't have to run per job.
37+ - pwsh : |
38+ foreach ($key in @(
39+ 'HKLM:\SOFTWARE\Microsoft\VisualStudio\Setup',
40+ 'HKLM:\SOFTWARE\Policies\Microsoft\VisualStudio\Setup')) {
41+ New-Item -Path $key -Force | Out-Null
42+ New-ItemProperty -Path $key -Name BackgroundDownload -PropertyType DWord -Value 0 -Force | Out-Null
43+ }
44+ Get-Process -Name BackgroundDownload -ErrorAction SilentlyContinue | Stop-Process -Force -ErrorAction SilentlyContinue
45+ displayName: Disable VS Installer background download
46+
3447 # The commit tag in the nuspec requires that we use at least nuget 5.8 (because things break with nuget versions before and Vs 16.8 or later)
3548 - task : NuGetToolInstaller@1
3649 displayName : Set NuGet version
You can’t perform that action at this time.
0 commit comments