mirror of
https://github.com/tinygo-org/tinygo.git
synced 2026-08-31 17:59:03 +00:00
ci: stop the LLVM caches from being evicted
The Actions cache of the repository was at 10.24 GB against a quota of 10 GB, so GitHub removed entries by least recent use. The LLVM entries were among the first to go, and CI then built LLVM again although the LLVM version did not change. The Docker buildx layer blobs held 6.0 GB of the quota. All LLVM caches together held 1.97 GB. Move the Docker layer cache to a registry cache in GHCR, which does not use the Actions quota. Both jobs have the necessary permission and login already. Pin the LLVM commit in llvm-version.txt and fetch that commit, in place of a clone of the branch tip tinygo_22.x. Add a hash of that file to each LLVM cache key, so a change of the LLVM version invalidates the caches and no other change does. Also rename the LLVM image tags from llvm-20 to llvm-22.
This commit is contained in:
@@ -35,8 +35,8 @@ jobs:
|
||||
uses: docker/metadata-action@v6
|
||||
with:
|
||||
images: |
|
||||
tinygo/llvm-20
|
||||
ghcr.io/${{ github.repository_owner }}/llvm-20
|
||||
tinygo/llvm-22
|
||||
ghcr.io/${{ github.repository_owner }}/llvm-22
|
||||
tags: |
|
||||
type=sha,format=long
|
||||
type=raw,value=latest
|
||||
@@ -59,5 +59,5 @@ jobs:
|
||||
push: true
|
||||
tags: ${{ steps.meta.outputs.tags }}
|
||||
labels: ${{ steps.meta.outputs.labels }}
|
||||
cache-from: type=gha
|
||||
cache-to: type=gha,mode=max
|
||||
cache-from: type=registry,ref=ghcr.io/${{ github.repository_owner }}/llvm-22:buildcache
|
||||
cache-to: type=registry,ref=ghcr.io/${{ github.repository_owner }}/llvm-22:buildcache,mode=max
|
||||
|
||||
Reference in New Issue
Block a user