This commit is contained in:
Will Greenberg 2022-08-22 15:23:27 -07:00
parent efcf36d40f
commit 406b7ccbc8

View file

@ -122,14 +122,13 @@ jobs:
vmImage: ubuntu-18.04
strategy:
matrix:
${{ each snap in parameters.snaps }}
${{ format('{0}-amd64:', snap }}
amd64:
SNAP_ARCH: amd64
# Do not run the heavy non-amd64 builds for test branches
${{ if not(startsWith(variables['Build.SourceBranchName'], 'test-')) }}:
${{ format('{0}-armhf', snap }}:
armhf:
SNAP_ARCH: armhf
${{ format('{0}-arm64', snap }}:
arm64:
SNAP_ARCH: arm64
timeoutInMinutes: 0
steps:
@ -147,14 +146,15 @@ jobs:
name: credentials
inputs:
secureFile: launchpad-credentials
- script: |
set -e
git config --global user.email "$(Build.RequestedForEmail)"
git config --global user.name "$(Build.RequestedFor)"
mkdir -p ~/.local/share/snapcraft/provider/launchpad
cp $(credentials.secureFilePath) ~/.local/share/snapcraft/provider/launchpad/credentials
python3 tools/snap/build_remote.py ALL --archs ${SNAP_ARCH} --timeout $(snapBuildTimeout)
displayName: Build snaps
- ${{ each snap parameters.snaps }}:
- script: |
set -e
git config --global user.email "$(Build.RequestedForEmail)"
git config --global user.name "$(Build.RequestedFor)"
mkdir -p ~/.local/share/snapcraft/provider/launchpad
cp $(credentials.secureFilePath) ~/.local/share/snapcraft/provider/launchpad/credentials
python3 tools/snap/build_remote.py $(snap) --archs ${SNAP_ARCH} --timeout $(snapBuildTimeout)
displayName: Build snaps
- script: |
set -e
mv *.snap $(Build.ArtifactStagingDirectory)