Skip to content

Commit 8b3ab1d

Browse files
committed
Use 'latest' tag for caching
1 parent 21fde67 commit 8b3ab1d

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

.github/workflows/docker.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,13 @@ jobs:
3232
- name: Build and push image
3333
run: |
3434
image_tag="ghcr.io/${{ github.repository }}:${{ github.run_id }}"
35+
latest_tag="ghcr.io/${{ github.repository }}:latest"
36+
3537
./build \
3638
--tag "$image_tag" \
37-
--push
39+
--tag "$latest_tag" \
40+
--push \
41+
--cache-from=type=registry,ref="$latest_tag"
3842
3943
cat >"$GITHUB_STEP_SUMMARY" <<~~
4044
Image successfully published.

0 commit comments

Comments
 (0)