Skip to content

Commit

Permalink
ci: lock all kas repos
Browse files Browse the repository at this point in the history
This guarantees that the build job can be easily replicated later.
The kas will generate a file named base.lock.yml which will later be used instead of base.yml,
we will save the lock file in the persistent storage.

Reference:
https://kas.readthedocs.io/en/latest/userguide/project-configuration.html#working-with-lockfiles

Signed-off-by: Jose Quaresma <[email protected]>
  • Loading branch information
quaresmajose committed Oct 15, 2024
1 parent 84fd9b0 commit 9a2eb54
Showing 1 changed file with 41 additions and 0 deletions.
41 changes: 41 additions & 0 deletions .github/workflows/build-yocto.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,50 @@ on:
- main

jobs:
kas-lock:
runs-on: [self-hosted, x86]
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Run kas lock
run: |
kas dump --update --lock --inplace ci/base.yml
- name: Prepare artifact
run: |
mkdir ci/lock
mv -v ci/*.lock.yml ci/lock
- uses: actions/upload-artifact@v4
with:
name: kas-lock
path: ci/lock

yocto-check-layer:
needs: kas-lock
runs-on: [self-hosted, x86]
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0

- uses: actions/download-artifact@v4
with:
name: kas-lock
path: ci/lock

- name: Prepare artifact
run: |
mv -v ci/lock/* ci
- name: Run yocto-check-layer
run: |
ci/yocto-check-layer.sh
compile:
needs: kas-lock
strategy:
fail-fast: true
matrix:
Expand All @@ -33,6 +65,15 @@ jobs:
with:
fetch-depth: 0

- uses: actions/download-artifact@v4
with:
name: kas-lock
path: ci/lock

- name: Prepare artifact
run: |
mv -v ci/lock/* ci
- name: Kas build
run: |
export DL_DIR=/srv/gh-runners/quic-yocto/downloads
Expand Down

0 comments on commit 9a2eb54

Please sign in to comment.