test all snap builds

This commit is contained in:
Brad Warren 2020-07-20 14:58:06 -07:00
parent 132ab7b517
commit b0421da79e

View file

@ -2,8 +2,12 @@ jobs:
- job: snap_build
strategy:
matrix:
amd64:
arch: amd64
armhf:
arch: armhf
arm64:
ARCH: arm64
arch: arm64
pool:
vmImage: ubuntu-18.04
steps:
@ -19,8 +23,12 @@ jobs:
- job: snap_dns_build
strategy:
matrix:
amd64:
arch: amd64
armhf:
arch: armhf
arm64:
ARCH: arm64
arch: arm64
pool:
vmImage: ubuntu-18.04
steps:
@ -33,3 +41,56 @@ jobs:
path: $(Build.ArtifactStagingDirectory)
artifact: dns-snap-$(arch)
displayName: Store snaps artifacts
- job: snap_run
dependsOn: snap_build
pool:
vmImage: ubuntu-18.04
steps:
- script: |
sudo apt-get update
sudo apt-get install -y --no-install-recommends nginx-light snapd
python tools/pip_install.py -U tox
displayName: Install dependencies
- task: DownloadPipelineArtifact@2
inputs:
artifact: snap-amd64
path: $(Build.SourcesDirectory)/snap
displayName: Retrieve Certbot snap
- script: |
sudo snap install --dangerous --classic snap/*.snap
displayName: Install Certbot snap
- script: |
python -m tox -e integration-external,apacheconftest-external-with-pebble
displayName: Run tox
- job: snap_dns_run
dependsOn:
- snap_build
- snap_dns_build
pool:
vmImage: ubuntu-18.04
steps:
- script: |
sudo apt-get update
sudo apt-get install -y --no-install-recommends snapd
displayName: Install dependencies
- task: UsePythonVersion@0
inputs:
versionSpec: 3.8
addToPath: true
- task: DownloadPipelineArtifact@2
inputs:
artifact: snap-amd64
path: $(Build.SourcesDirectory)/snap
displayName: Retrieve Certbot snap
- task: DownloadPipelineArtifact@2
inputs:
artifact: dns-snap-amd64
path: $(Build.SourcesDirectory)/snap
displayName: Retrieve Certbot DNS plugins snaps
- script: |
python3 -m venv venv
venv/bin/python tools/pip_install.py -e certbot-ci
displayName: Prepare Certbot-CI
- script: |
sudo -E venv/bin/pytest certbot-ci/snap_integration_tests/dns_tests --allow-persistent-changes --snap-folder $(Build.SourcesDirectory)/snap
displayName: Test DNS plugins snaps