Make CI cache config explicit for all jobs; disable cache for all jobs that don't build Rust code.
This commit is contained in:
parent
f7e4aa74d9
commit
195eb4b243
1 changed files with 15 additions and 5 deletions
|
@ -1,5 +1,5 @@
|
|||
# SPDX-FileCopyrightText: 2021-2022 Heiko Schaefer <heiko@schaefer.name>
|
||||
# SPDX-FileCopyrightText: 2021 Nora Widdecke <mail@nora.pink>
|
||||
# SPDX-FileCopyrightText: 2021-2022 Nora Widdecke <mail@nora.pink>
|
||||
# SPDX-License-Identifier: CC0-1.0
|
||||
|
||||
stages:
|
||||
|
@ -24,7 +24,6 @@ cache: &general_cache_config
|
|||
|
||||
pages:
|
||||
stage: pages
|
||||
cache: [ ]
|
||||
image: debian:stable-slim
|
||||
before_script:
|
||||
- apt update -y -qq
|
||||
|
@ -36,16 +35,17 @@ pages:
|
|||
artifacts:
|
||||
paths:
|
||||
- public
|
||||
cache: [ ]
|
||||
|
||||
reuse:
|
||||
stage: lint
|
||||
cache: [ ]
|
||||
image:
|
||||
name: fsfe/reuse:latest
|
||||
entrypoint: [ "" ]
|
||||
script:
|
||||
- reuse lint
|
||||
dependencies: []
|
||||
dependencies: [ ]
|
||||
cache: [ ]
|
||||
|
||||
cargo-fmt:
|
||||
stage: lint
|
||||
|
@ -53,6 +53,7 @@ cargo-fmt:
|
|||
script:
|
||||
- rustup component add rustfmt
|
||||
- cargo fmt -- --check
|
||||
cache: [ ]
|
||||
|
||||
cargo-deny:
|
||||
stage: lint
|
||||
|
@ -61,6 +62,7 @@ cargo-deny:
|
|||
- cargo install --locked cargo-deny
|
||||
script:
|
||||
- cargo deny check
|
||||
cache: [ ]
|
||||
|
||||
cargo-clippy:
|
||||
stage: lint
|
||||
|
@ -73,11 +75,15 @@ cargo-clippy:
|
|||
script:
|
||||
- rustup component add clippy
|
||||
- cargo clippy --verbose --tests -- -D warnings
|
||||
cache:
|
||||
# inherit all general cache settings
|
||||
<<: *general_cache_config
|
||||
# override the key
|
||||
key: "rust-latest"
|
||||
|
||||
udeps:
|
||||
stage: lint
|
||||
image: rustlang/rust:nightly-slim
|
||||
cache: [ ]
|
||||
before_script:
|
||||
- mkdir -p /run/user/$UID
|
||||
- apt update -y -qq
|
||||
|
@ -87,6 +93,7 @@ udeps:
|
|||
- tar --extract --verbose --gzip --file /tmp/cargo-udeps.tar.gz --directory /usr/local/bin/ --strip-components=2 ./cargo-udeps-v0.1.26-x86_64-unknown-linux-gnu/cargo-udeps
|
||||
script:
|
||||
- cargo udeps --workspace --all-features --all-targets
|
||||
cache: [ ]
|
||||
|
||||
cargo-test:
|
||||
stage: test
|
||||
|
@ -134,6 +141,7 @@ run_cardtest_smartpgp:
|
|||
# inherit all general cache settings
|
||||
<<: *general_cache_config
|
||||
# override the key
|
||||
# (the base image of run_cardtest uses bookworm)
|
||||
key: "bookworm"
|
||||
|
||||
run_cardtest_ykneo:
|
||||
|
@ -150,6 +158,7 @@ run_cardtest_ykneo:
|
|||
# inherit all general cache settings
|
||||
<<: *general_cache_config
|
||||
# override the key
|
||||
# (the base image of run_cardtest uses bookworm)
|
||||
key: "bookworm"
|
||||
|
||||
hardware-builddeps:
|
||||
|
@ -174,6 +183,7 @@ hardware-builddeps:
|
|||
IMAGE_LATEST: $CI_REGISTRY_IMAGE/hardware-builddeps:latest
|
||||
IMAGE_SHA: $CI_REGISTRY_IMAGE/hardware-builddeps:$CI_COMMIT_SHA
|
||||
DOCKERFILE: card-functionality/docker/Dockerfile.hardware-builddeps
|
||||
cache: [ ]
|
||||
|
||||
.hw-test-template:
|
||||
image: registry.gitlab.com/hkos/openpgp-card/hardware-builddeps
|
||||
|
|
Loading…
Reference in a new issue