Skip to content

Commit

Permalink
ci: Update azure podvm image build to use oras
Browse files Browse the repository at this point in the history
Signed-off-by: Magnus Kulke <magnuskulke@microsoft.com>
  • Loading branch information
mkulke committed Sep 13, 2024
1 parent 453846c commit 9e7d846
Showing 1 changed file with 11 additions and 12 deletions.
23 changes: 11 additions & 12 deletions .github/workflows/azure-podvm-image-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,11 +47,9 @@ jobs:
path: cloud-api-adaptor
ref: "${{ inputs.git-ref || 'main' }}"

- name: Clone rust repos
run: |
# we have to clone prior to cache loading
make ../../podvm/..//../kata-containers
make ../../../guest-components
# we have to clone prior to cache loading
- name: Clone guest-componetns
run: make ../../../guest-components

- name: Read properties from versions.yaml
working-directory: cloud-api-adaptor/src/cloud-api-adaptor
Expand All @@ -64,6 +62,10 @@ jobs:
[ -n "$rust_version" ]
echo "RUST_VERSION=${rust_version}" >> "$GITHUB_ENV"
oras_version="$(yq '.tools.oras' versions.yaml)"
[ -n "$oras_version" ]
echo "ORAS_VERSION=${oras_version}" >> "$GITHUB_ENV"
- name: Set up Go environment
uses: actions/setup-go@v4
with:
Expand All @@ -77,12 +79,15 @@ jobs:
target: x86_64-unknown-linux-musl
default: true

- uses: oras-project/setup-oras@v1
with:
version: ${{ env.ORAS_VERSION }}

- name: Install build dependencies
run: |
sudo apt-get update
sudo apt-get install -y \
clang \
gcc \
libdevmapper-dev \
libgpgme-dev \
libssl-dev \
Expand All @@ -98,14 +103,8 @@ jobs:
~/.cargo/registry/index/
~/.cargo/registry/cache/
guest-components/target
kata-containers/src/agent/target
key: rust-${{ env.RUST_VERSION }}

- name: Build kata-agent
env:
GOPATH: /home/runner/go
run: make "$(realpath ../../podvm/files/usr/local/bin/kata-agent)" LIBC=gnu

- name: Build binaries
run: make binaries \
ATTESTER="az-snp-vtpm-attester,az-tdx-vtpm-attester" \
Expand Down

0 comments on commit 9e7d846

Please sign in to comment.