Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(ci): Cache integration test image #166

Merged
merged 3 commits into from
Mar 4, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 20 additions & 2 deletions .github/workflows/act_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,7 @@ jobs:
target:
- aarch64-unknown-linux-gnu
- aarch64-unknown-linux-musl
- armv7-unknown-linux-gnueabihf
- armv7-unknown-linux-musleabihf
- i686-unknown-linux-gnu
- i686-unknown-linux-musl
- x86_64-unknown-linux-gnu
- x86_64-unknown-linux-musl
Expand Down Expand Up @@ -172,6 +170,26 @@ jobs:
sudo apt-get update
sudo apt-get install -y podman
podman --version
- name: Cache podman image
id: cache-podman
uses: actions/cache@v4
with:
path: |
~/podman_cache
key: integration_tests-${{ runner.os }}-${{ hashFiles('integration_tests/images/arch/Containerfile') }}
- name: Load cached image
if: steps.cache-podman.outputs.cache-hit == 'true'
run: |-
set +ex
podman load < ~/podman_cache/test_img.tar
- name: Build & cache image
if: steps.cache-podman.outputs.cache-hit != 'true'
run: |-
set +ex
cd integration_tests/images/arch
./build_image.sh
mkdir -p ~/podman_cache
podman save localhost/test_img > ~/podman_cache/test_img.tar
- name: Run integration tests
run: |-
cd integration_tests
Expand Down
2 changes: 1 addition & 1 deletion integration_tests/images/arch/Containerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM docker.io/archlinux/archlinux:base-devel-20250302.0.316047 AS base_image
FROM ghcr.io/archlinux/archlinux:base-devel-20250302.0.316047 AS base_image

# Signatures expire, repos expire, and so on. Make this image reproducible
# (update this once in a while)
Expand Down