Skip to content

Commit 3168a49

Browse files
TravisEz13jshigetomiJustin Chung
authored
Fixed release pipeline errors and switched to KS3 (#24751) (#24816)
* Fixed an error in the release pipeline * Fixed ReleaseTag and Version variable in validate packages * Switched from Netlock to KS3 --------- Co-authored-by: Justin Chung <124807742+jshigetomi@users.noreply.github.com> Co-authored-by: Justin Chung <chungjustin@microsoft.com>
1 parent 03cf0c6 commit 3168a49

7 files changed

+11
-9
lines changed

.pipelines/PowerShell-Release-Official.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,8 @@ extends:
8888
LinuxHostVersion:
8989
Network: Monitor
9090
WindowsHostVersion:
91-
Network: Monitor
91+
Version: 2022
92+
Network: KS3
9293
cloudvault:
9394
enabled: false
9495
globalSdl:

.pipelines/templates/release-SetReleaseTagandContainerName.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,12 @@ steps:
1515
displayName: Set Release Tag
1616

1717
- pwsh: |
18-
$azureVersion = '$(ReleaseTag)'.ToLowerInvariant() -replace '\.', '-'
19-
$vstsCommandString = "vso[task.setvariable variable=AzureVersion]$azureVersion"
18+
$azureVersion = '$(OutputReleaseTag.ReleaseTag)'.ToLowerInvariant() -replace '\.', '-'
19+
$vstsCommandString = "vso[task.setvariable variable=AzureVersion;isOutput=true]$azureVersion"
2020
Write-Host "sending " + $vstsCommandString
2121
Write-Host "##$vstsCommandString"
2222
23-
$version = '$(ReleaseTag)'.ToLowerInvariant().Substring(1)
23+
$version = '$(OutputReleaseTag.ReleaseTag)'.ToLowerInvariant().Substring(1)
2424
$vstsCommandString = "vso[task.setvariable variable=Version;isOutput=true]$version"
2525
Write-Host ("sending " + $vstsCommandString)
2626
Write-Host "##$vstsCommandString"

.pipelines/templates/release-create-msix.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ jobs:
9696
azurePowerShellVersion: LatestVersion
9797
pwsh: true
9898
inline: |
99-
$containerName = '$(AzureVersion)-private'
99+
$containerName = '$(OutputVersion.AzureVersion)-private'
100100
$storageAccount = '$(StorageAccount)'
101101
102102
$storageContext = New-AzStorageContext -StorageAccountName $storageAccount -UseConnectedAccount

.pipelines/templates/release-githubtasks.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ jobs:
6363
pwsh: true
6464
script: |
6565
Import-module '$(Pipeline.Workspace)/ToolArtifact/GitHubRelease.psm1'
66+
$releaseVersion = '$(ReleaseTag)' -replace '^v',''
6667
Write-Verbose -Verbose "Available modules: "
6768
Get-Module | Write-Verbose -Verbose
6869

.pipelines/templates/release-validate-globaltools.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ jobs:
8585
$packageName = '${{ parameters.globalToolPackageName }}'
8686
Write-Verbose -Verbose "Installing $packageName"
8787
88-
dotnet tool install --add-source "$ENV:PIPELINE_WORKSPACE/PSPackagesOfficial/drop_nupkg_build_nupkg" --tool-path $toolPath --version '$(Version)' $packageName
88+
dotnet tool install --add-source "$ENV:PIPELINE_WORKSPACE/PSPackagesOfficial/drop_nupkg_build_nupkg" --tool-path $toolPath --version '$(OutputVersion.Version)' $packageName
8989
9090
Get-ChildItem -Path $toolPath
9191
@@ -133,7 +133,7 @@ jobs:
133133
134134
$versionFound = & $toolPath -c '$PSVersionTable.PSVersion.ToString()'
135135
136-
if ( '$(Version)' -ne $versionFound)
136+
if ( '$(OutputVersion.Version)' -ne $versionFound)
137137
{
138138
throw "Expected version of global tool not found. Installed version is $versionFound"
139139
}

.pipelines/templates/release-validate-packagenames.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ jobs:
5050
inline: |
5151
$storageAccount = Get-AzStorageAccount -ResourceGroupName '$(StorageResourceGroup)' -Name '$(StorageAccount)'
5252
$ctx = $storageAccount.Context
53-
$container = '$(AzureVersion)'
53+
$container = '$(OutputVersion.AzureVersion)'
5454
5555
$destinationPath = '$(System.ArtifactsDirectory)'
5656
$blobList = Get-AzStorageBlob -Container $container -Context $ctx

.pipelines/templates/release-validate-sdk.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ jobs:
9595
</packageSources>
9696
"@
9797
98-
$releaseVersion = '$(Version)'
98+
$releaseVersion = '$(OutputVersion.Version)'
9999
100100
Write-Verbose -Message "Release Version: $releaseVersion" -Verbose
101101

0 commit comments

Comments
 (0)