Skip to content

Commit

Permalink
updated azure-pipelines.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
HariSekhon committed Sep 21, 2024
1 parent f108bf8 commit c06e876
Showing 1 changed file with 12 additions and 5 deletions.
17 changes: 12 additions & 5 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,19 +22,26 @@
trigger:
- master

variables:
# ubuntu version
os_version: '22.04'

pool:
# there is no /dev/stderr on this azure build!
#vmImage: 'ubuntu-latest'
# Ubuntu 16.04 required for docker container support, looks like 18.04 works too
vmImage: 'ubuntu-22.04'
#vmImage: 'ubuntu-22.04'
vmImage: 'ubuntu-$(os_version)'

# unprivileged container without sudo, cannot install dependencies
#container: ubuntu:18.04
#container: ubuntu:22.04

steps:
- script: cat /etc/*-release
displayName: OS Release

# requires script as first key, otherwise parsing breaks with error message: Unexpected value 'displayName'
- script: env | sort
displayName: env
displayName: Environment

# doesn't work in container due to unprivileged execution and lack of sudo
#- script: sudo apt-get update && sudo apt-get install -y git make
Expand All @@ -50,7 +57,7 @@ steps:

# hacky workaround to Azure Pipelines ubuntu environment limitations of unprivileged container and no /dev/stderr in vmImage :-(
- script: |
sudo docker run -v "$PWD":/code ubuntu:18.04 /bin/bash -c '
sudo docker run -v "$PWD":/code "ubuntu:$(os_version)" /bin/bash -c '
set -ex
cd /code
setup/ci_bootstrap.sh
Expand Down

0 comments on commit c06e876

Please # to comment.