From bbe92d08cf00d86cb0a05adc6fa4810118845a21 Mon Sep 17 00:00:00 2001 From: Sergio Arroutbi Date: Wed, 3 Sep 2025 09:39:20 +0200 Subject: [PATCH 1/6] Include CI GH action to avoid compilation warnings Signed-off-by: Sergio Arroutbi --- .github/workflows/compile-no-warnings.yml | 28 +++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 .github/workflows/compile-no-warnings.yml diff --git a/.github/workflows/compile-no-warnings.yml b/.github/workflows/compile-no-warnings.yml new file mode 100644 index 00000000..4b4c0fac --- /dev/null +++ b/.github/workflows/compile-no-warnings.yml @@ -0,0 +1,28 @@ +--- +name: Rust + +"on": + push: + branches: [master] + pull_request: + branches: [master] + +env: + CARGO_TERM_COLOR: always + +jobs: + basic-compilation: + name: Compilation with no warnings + runs-on: ubuntu-latest + container: + image: quay.io/keylime/keylime-ci:latest + steps: + - uses: actions/checkout@v6 + - name: Check compilation (no warnings) + run: RUSTFLAGS="-D warnings" cargo build + - name: Check test compilation (no warnings) + run: RUSTFLAGS="-D warnings" cargo test + - name: Check clippy errors (no warnings included) + run: cargo clippy --all-features --all-targets -- -D clippy::all -D warnings + - name: Check clippy test errors (no warnings included) + run: cargo clippy --all-features --all-targets --tests -- -D clippy::all -D warnings From 547b101b0288659b39bbc3f4d7c14138b5083eda Mon Sep 17 00:00:00 2001 From: Sergio Arroutbi Date: Mon, 27 Apr 2026 15:20:20 +0200 Subject: [PATCH 2/6] Fix no-warnings CI workflow Rename workflow from "Rust" to "No-Warnings Compilation" to avoid collision with rust.yml, add --no-run to cargo test so it only checks compilation, and remove the duplicate clippy step since --all-targets already includes test targets. Co-Authored-By: Claude Opus 4.6 Signed-off-by: Sergio Arroutbi --- .github/workflows/compile-no-warnings.yml | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/.github/workflows/compile-no-warnings.yml b/.github/workflows/compile-no-warnings.yml index 4b4c0fac..caed5d60 100644 --- a/.github/workflows/compile-no-warnings.yml +++ b/.github/workflows/compile-no-warnings.yml @@ -1,5 +1,5 @@ --- -name: Rust +name: No-Warnings Compilation "on": push: @@ -21,8 +21,6 @@ jobs: - name: Check compilation (no warnings) run: RUSTFLAGS="-D warnings" cargo build - name: Check test compilation (no warnings) - run: RUSTFLAGS="-D warnings" cargo test + run: RUSTFLAGS="-D warnings" cargo test --no-run - name: Check clippy errors (no warnings included) run: cargo clippy --all-features --all-targets -- -D clippy::all -D warnings - - name: Check clippy test errors (no warnings included) - run: cargo clippy --all-features --all-targets --tests -- -D clippy::all -D warnings From a5426da913aafdada2419975b5208c16bfc46a41 Mon Sep 17 00:00:00 2001 From: Sergio Arroutbi Date: Mon, 27 Apr 2026 16:27:33 +0200 Subject: [PATCH 3/6] Add git safe.directory to no-warnings CI job The container job can hit "dubious ownership" errors when build scripts or tools access repository metadata. Add the same safe.directory step already used in rust.yml. Co-Authored-By: Claude Opus 4.6 Signed-off-by: Sergio Arroutbi --- .github/workflows/compile-no-warnings.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/compile-no-warnings.yml b/.github/workflows/compile-no-warnings.yml index caed5d60..5077bfc6 100644 --- a/.github/workflows/compile-no-warnings.yml +++ b/.github/workflows/compile-no-warnings.yml @@ -18,6 +18,8 @@ jobs: image: quay.io/keylime/keylime-ci:latest steps: - uses: actions/checkout@v6 + - name: Set git safe.directory for the working directory + run: git config --system --add safe.directory "$PWD" - name: Check compilation (no warnings) run: RUSTFLAGS="-D warnings" cargo build - name: Check test compilation (no warnings) From 1f8e44983e4d099e2731ac99f7240a4ecd0e7a10 Mon Sep 17 00:00:00 2001 From: Sergio Arroutbi Date: Mon, 27 Apr 2026 17:07:47 +0200 Subject: [PATCH 4/6] Fix extra space in clippy command in CI workflow Co-Authored-By: Claude Opus 4.6 Signed-off-by: Sergio Arroutbi --- .github/workflows/compile-no-warnings.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/compile-no-warnings.yml b/.github/workflows/compile-no-warnings.yml index 5077bfc6..6d339fab 100644 --- a/.github/workflows/compile-no-warnings.yml +++ b/.github/workflows/compile-no-warnings.yml @@ -25,4 +25,4 @@ jobs: - name: Check test compilation (no warnings) run: RUSTFLAGS="-D warnings" cargo test --no-run - name: Check clippy errors (no warnings included) - run: cargo clippy --all-features --all-targets -- -D clippy::all -D warnings + run: cargo clippy --all-features --all-targets -- -D clippy::all -D warnings From b0e5ecd753493ca626c9c175b692d8164cd7d393 Mon Sep 17 00:00:00 2001 From: Sergio Arroutbi Date: Tue, 28 Apr 2026 10:32:58 +0200 Subject: [PATCH 5/6] Pin CI image to digest in no-warnings workflow Replace mutable :latest tag with sha256 digest for reproducible builds. Include a comment with the skopeo command to refresh the digest. Co-Authored-By: Claude Opus 4.6 Signed-off-by: Sergio Arroutbi --- .github/workflows/compile-no-warnings.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/compile-no-warnings.yml b/.github/workflows/compile-no-warnings.yml index 6d339fab..0b50f07a 100644 --- a/.github/workflows/compile-no-warnings.yml +++ b/.github/workflows/compile-no-warnings.yml @@ -15,7 +15,8 @@ jobs: name: Compilation with no warnings runs-on: ubuntu-latest container: - image: quay.io/keylime/keylime-ci:latest + # To refresh: skopeo inspect --no-tags docker://quay.io/keylime/keylime-ci:latest | jq -r '.Digest' + image: quay.io/keylime/keylime-ci@sha256:973f36045d0dd0b1a219dd88f06625c65a77f267842ee23d955e0c095ef09ff2 steps: - uses: actions/checkout@v6 - name: Set git safe.directory for the working directory From 79636969069234acd682a092dcbf771a2082607a Mon Sep 17 00:00:00 2001 From: Sergio Arroutbi Date: Wed, 13 May 2026 11:36:06 +0200 Subject: [PATCH 6/6] Fix compilation warning Signed-off-by: Sergio Arroutbi --- keylime/src/context_info.rs | 1 - 1 file changed, 1 deletion(-) diff --git a/keylime/src/context_info.rs b/keylime/src/context_info.rs index 88069498..cae6f713 100644 --- a/keylime/src/context_info.rs +++ b/keylime/src/context_info.rs @@ -790,7 +790,6 @@ impl ContextInfo { mod uefi_log_tests { use super::base64_standard; use super::*; - use base64::Engine as _; /// Cached bytes are preferred over the on-disk file. ///