Skip to content

Commit

Permalink
.github/workflows: Build DTS from kas-uefi-sb.yml
Browse files Browse the repository at this point in the history
Signed-off-by: Pawel Langowski <[email protected]>
  • Loading branch information
PLangowski committed Feb 6, 2025
1 parent 5748aa6 commit 674aa80
Show file tree
Hide file tree
Showing 5 changed files with 40 additions and 4 deletions.
7 changes: 5 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ on:
cacheless:
type: boolean
required: true
kas-path:
type: string
required: true

jobs:
build:
Expand All @@ -22,13 +25,13 @@ jobs:
if: ${{ inputs.cacheless }}
shell: bash
run: |
sed -i '/cache.yml/d' meta-dts/kas.yml
sed -i '/cache.yml/d' "${{ inputs.kas-path }}"
- name: Build DTS image
shell: bash
id: build_image
run: |
for attempt in {1..5}; do
if kas-container build meta-dts/kas.yml; then
if kas-container build "${{ inputs.kas-path }}"; then
echo "Build command succeeded on attempt $attempt"
break
else
Expand Down
17 changes: 16 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,25 @@ concurrency:
group: run-only-one-workflow

jobs:
build-uefi-sb:
uses: ./.github/workflows/build.yml
with:
cacheless: false
kas-path: meta-dts/kas-uefi-sb.yml
move-build-artifacts:
needs: build-uefi-sb
runs-on:
labels: dts-builder
steps:
- name: Move UEFI SB build artifacts
run: |
mv build build-sb
build:
needs: move-build-artifacts
uses: ./.github/workflows/build.yml
with:
cacheless: false
kas-path: meta-dts/kas.yml
deploy-images:
name: Deploy DTS artifacts on boot.dasharo.com and GitHub Release
needs: build
Expand Down Expand Up @@ -134,4 +149,4 @@ jobs:
rm -rf ~/.ssh/dts-ci-key
rm -rf dts-release-cicd-pipeline
rm -f ~/.ssh/gitea_dts_release_cicd
rm -rf build meta-dts
rm -rf build build-sb meta-dts
17 changes: 16 additions & 1 deletion .github/workflows/develop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,25 @@ concurrency:
group: run-only-one-workflow

jobs:
build-uefi-sb:
uses: ./.github/workflows/build.yml
with:
cacheless: false
kas-path: meta-dts/kas-uefi-sb.yml
move-build-artifacts:
needs: build-uefi-sb
runs-on:
labels: dts-builder
steps:
- name: Move UEFI SB build artifacts
run: |
mv build build-sb
build:
needs: move-build-artifacts
uses: ./.github/workflows/build.yml
with:
cacheless: false
kas-path: meta-dts/kas.yml
deploy-images:
name: Deploy DTS artifacts on boot.dasharo.com
needs: build
Expand Down Expand Up @@ -125,4 +140,4 @@ jobs:
rm -rf ~/.ssh/dts-ci-key
rm -rf dts-release-cicd-pipeline
rm -f ~/.ssh/gitea_dts_release_cicd
rm -rf build meta-dts
rm -rf build build-sb meta-dts
1 change: 1 addition & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ jobs:
uses: ./.github/workflows/build.yml
with:
cacheless: false
kas-path: meta-dts/kas.yml

checkout-osfv:
runs-on: dts-builder
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/weekly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ jobs:
uses: ./.github/workflows/build.yml
with:
cacheless: true
kas-path: meta-dts/kas.yml

deploy-cache:
name: Deploy cache on cache.dasharo.com
needs: build
Expand Down

0 comments on commit 674aa80

Please sign in to comment.