From d8d5581e825a330875910111698ab5a4337fc8e9 Mon Sep 17 00:00:00 2001 From: gquadrati <75862507+gquadrati@users.noreply.github.com> Date: Mon, 8 Feb 2021 16:47:16 +0100 Subject: [PATCH] [#176591026] Added new stage for deploying client SDK to NPM (#124) --- .devops/deploy-pipelines.yml | 27 +++++++++++++++++++++++---- 1 file changed, 23 insertions(+), 4 deletions(-) diff --git a/.devops/deploy-pipelines.yml b/.devops/deploy-pipelines.yml index 1b2ced66..5e514d4b 100644 --- a/.devops/deploy-pipelines.yml +++ b/.devops/deploy-pipelines.yml @@ -28,11 +28,17 @@ pool: resources: repositories: - - repository: pagopaCommons + - repository: pagopaCommonsLegacy type: github name: pagopa/azure-pipeline-templates ref: refs/tags/v4 endpoint: 'pagopa' + + - repository: pagopaCommons + type: github + name: pagopa/azure-pipeline-templates + ref: refs/tags/v10 + endpoint: 'pagopa' stages: @@ -58,7 +64,7 @@ stages: - job: make_release steps: - ${{ if eq(variables['Build.SourceBranch'], 'refs/heads/master') }}: - - template: templates/node-github-release/template.yaml@pagopaCommons + - template: templates/node-github-release/template.yaml@pagopaCommonsLegacy parameters: semver: '${{ parameters.RELEASE_SEMVER }}' gitEmail: $(GIT_EMAIL) @@ -73,7 +79,6 @@ stages: echo "We assume this reference to be a valid release: $(Build.SourceBranch). Therefore, there is no need to bundle a new release." displayName: 'Skip release bundle' - # Prepare Artifact - stage: Deploy_staging dependsOn: @@ -140,7 +145,7 @@ stages: jobs: - job: 'do_healthcheck' steps: - - template: templates/rest-healthcheck/template.yaml@pagopaCommons + - template: templates/rest-healthcheck/template.yaml@pagopaCommonsLegacy parameters: azureSubscription: '$(PRODUCTION_AZURE_SUBSCRIPTION)' appName: '$(PRODUCTION_APP_NAME)' @@ -166,3 +171,17 @@ stages: sourceSlot: staging swapWithProduction: true displayName: Swap with production slot + + + # Publish client SDK to NPM + - stage: PublishClientSDKtoNPM + dependsOn: Release + pool: + vmImage: 'ubuntu-latest' + jobs: + - job: publish_SDK + steps: + # Template for generating and deploying client SDk to NPM + - template: templates/client-sdk-publish/template.yaml@pagopaCommons + parameters: + openapiSpecPath: 'openapi/index.yaml'