Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CI] Move the sing and notarize steps to a VM. #14854

Merged
merged 3 commits into from
May 2, 2022
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions tools/devops/automation/build-pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -346,8 +346,6 @@ stages:
keyringPass: $(pass--lab--mac--builder--keychain)
enableDotnet: ${{ parameters.enableDotnet }}
skipESRP: ${{ parameters.skipESRP }}
pool: ${{ parameters.pool }}


- ${{ if eq(parameters.enableAPIDiff, true) }}:
- stage: generate_api_diff
Expand Down
33 changes: 1 addition & 32 deletions tools/devops/automation/templates/build/prepare-pkg-stage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,6 @@ parameters:
type: boolean
default: false # only to be used when testing the CI and we do not need a signed pkg

- name: pool
type: string
default: automatic

jobs:
- job: configure
displayName: 'Configure build'
Expand All @@ -28,40 +24,13 @@ jobs:
steps:
- template: ../common/configure.yml

- ${{ if eq(parameters.pool, 'automatic') }}:
- job: AgentPoolSelector # https://docs.microsoft.com/en-us/azure/devops/pipelines/process/phases?view=azure-devops&tabs=yaml
pool: # Consider using an agentless (server) job here, but would need to host selection logic as an Azure function: https://docs.microsoft.com/en-us/azure/devops/pipelines/yaml-schema?view=azure-devops&tabs=schema#server
vmImage: ubuntu-latest
steps:
- checkout: none # https://docs.microsoft.com/en-us/azure/devops/pipelines/yaml-schema?view=azure-devops&tabs=schema#checkout

# Selects appropriate agent pool based on trigger type (PR or CI); manually triggered builds target the PR pool
- template: azure-devops-pools/agent-pool-selector.yml@templates
parameters:
agentPoolPR: $(PRBuildPool)
agentPoolPRUrl: $(PRBuildPoolUrl)
agentPoolCI: $(CIBuildPool)
agentPoolCIUrl: $(CIBuildPoolUrl)

- job: sign_notarize
dependsOn:
- ${{ if eq(parameters.pool, 'automatic') }}:
- AgentPoolSelector
- configure
displayName: 'Sign & Notarize'
timeoutInMinutes: 1000
variables:
${{ if eq(parameters.pool, 'automatic') }}:
AgentPoolComputed: $[ dependencies.AgentPoolSelector.outputs['setAgentPool.AgentPoolComputed'] ]
${{ if eq(parameters.pool, 'ci') }}:
AgentPoolComputed: $(CIBuildPool)
${{ if eq(parameters.pool, 'pr') }}:
AgentPoolComputed: $(PRBuildPool)
pool:
name: $(AgentPoolComputed)
demands:
- Agent.OS -equals Darwin
- macios_image -equals v2.1 # Big Sur image with Xcode 12.4 and 12.5 installed
vimImage: internal-macos12
workspace:
clean: all

Expand Down