Skip to content

Commit bdf56dd

Browse files
committed
Update github actions
- Build on the Oxide Colo runner - Package and attest
1 parent cc132f9 commit bdf56dd

2 files changed

Lines changed: 20 additions & 3 deletions

File tree

.github/workflows/build.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,3 +33,5 @@ jobs:
3333
key: ${{ runner.os }}-rustup-${{ hashFiles('rust-toolchain.toml') }}
3434
- name: Build
3535
run: cargo build
36+
- name: Package
37+
run: cargo xtask package --out file.zip --board lpc55xpresso

.github/workflows/release-build.yml

Lines changed: 18 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,11 @@ env:
1212

1313
jobs:
1414
release-build:
15-
runs-on: ubuntu-latest
16-
15+
runs-on: oxide-colo-builder-hubris
16+
permissions:
17+
id-token: write
18+
attestations: write
19+
contents: write
1720
strategy:
1821
matrix:
1922
board:
@@ -32,8 +35,12 @@ jobs:
3235
sudo apt-get update && sudo apt-get install binutils-arm-none-eabi
3336
3437
- name: Build
38+
id: build
3539
run: |
36-
cargo build --release --no-default-features --features target-board-${{ matrix.board }}
40+
PACKAGE_NAME=bootleby-${{ matrix.board }}
41+
echo "package_name=${PACKAGE_NAME}" >> "${GITHUB_OUTPUT}"
42+
# This implicitly calls `cargo build --release`
43+
cargo xtask package --board ${{ matrix.board }} --out ${PACKAGE_NAME}.zip
3744
3845
- name: Package artifacts
3946
id: package
@@ -57,13 +64,20 @@ jobs:
5764
# Make some info available for later steps
5865
echo "build_name=${BUILD_NAME}" >> "${GITHUB_OUTPUT}"
5966
67+
68+
- name: Attestation
69+
uses: actions/attest-build-provenance@v1
70+
with:
71+
subject-path: ${{ steps.build.outputs.package_name }}.zip
72+
6073
- name: Upload artifacts
6174
uses: actions/upload-artifact@v4
6275
with:
6376
name: ${{ steps.package.outputs.build_name }}
6477
path: |
6578
${{ steps.package.outputs.build_name }}.elf
6679
${{ steps.package.outputs.build_name }}.bin
80+
${{ steps.build.outputs.package_name }}.zip
6781
6882
- name: Create release if tagged
6983
if: startsWith(github.ref, 'refs/tags/')
@@ -86,3 +100,4 @@ jobs:
86100
files: |
87101
${{ steps.package.outputs.build_name}}.elf
88102
${{ steps.package.outputs.build_name}}.bin
103+
${{ steps.build.outputs.package_name }}.zip

0 commit comments

Comments
 (0)