Skip to content

Commit

Permalink
ci: cache container images to GitHub Actions cache
Browse files Browse the repository at this point in the history
  • Loading branch information
indygreg committed Jul 20, 2023
1 parent 46afb24 commit 7a411e6
Showing 1 changed file with 18 additions and 1 deletion.
19 changes: 18 additions & 1 deletion .github/workflows/linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,26 @@ jobs:
with:
python-version: '3.11'

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2

- name: Generate Dockerfiles
run: |
./build-linux.py --make-target empty
- name: Build Image
uses: docker/build-push-action@v4
with:
file: build/${{ matrix.image }}.Dockerfile
cache-from: |
type=gha
cache-to: |
type=gha
outputs: |
type=tar,dest=build/image-${{ matrix.image }}.tar
- name: Compress Image
run: |
./build-linux.py --make-target toolchain-image-${{ matrix.image }}
zstd -v -T0 -6 --rm build/image-*.tar
- name: Upload Docker Image
Expand Down

0 comments on commit 7a411e6

Please sign in to comment.