diff --git a/build/azure-pipelines.yml b/build/azure-pipelines.yml index 4b4a99c9fc..14f58b7363 100644 --- a/build/azure-pipelines.yml +++ b/build/azure-pipelines.yml @@ -243,8 +243,6 @@ stages: - deployment: gitHub displayName: GitHub Packages environment: GitHub - variables: - GITHUB_PACKAGES_APIKEY: $(GitHubPushPackagesAPIKey) # key is set in UI of Azure Devops strategy: runOnce: deploy: @@ -269,19 +267,11 @@ stages: runOnce: deploy: steps: - - download: current - artifact: NuGetPackages - displayName: Download artifact NuGetPackages - - task: NuGetCommand@2 - displayName: 'NuGet Push packages' - inputs: - command: push - packagesToPush: '$(Agent.BuildDirectory)/NuGetPackages/*.*nupkg' - nuGetFeedType: external - publishFeedCredentials: NuGet - verbosityPush: normal - includeSymbols: true - + - template: push-nuget-package.yml@templates + parameters: + artifact: 'NuGetPackages' + source: https://api.nuget.org/v3/index.json + apiKey: $(NUGET_APIKEY) - deployment: relNotes displayName: Release Notes environment: NuGet diff --git a/build/pipeline-variables.yml b/build/pipeline-variables.yml index f729760f5e..fce8d4a676 100644 --- a/build/pipeline-variables.yml +++ b/build/pipeline-variables.yml @@ -3,4 +3,6 @@ # Variables used during the whole pipeline. variables: - isTagBranch: $[startswith(variables['Build.SourceBranch'], 'refs/tags/v')] \ No newline at end of file + isTagBranch: $[startswith(variables['Build.SourceBranch'], 'refs/tags/v')] + GITHUB_PACKAGES_APIKEY: $(GitHubPushPackagesAPIKey) # key is set in UI of Azure Devops + NUGET_APIKEY: $(NuGetAPIKey) # key is set in UI of Azure Devops \ No newline at end of file