Skip to content

Commit c681e83

Browse files
committed
ci improvements - fixing buildx with cache
1 parent d17a5c1 commit c681e83

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

.github/workflows/ci.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -222,13 +222,14 @@ jobs:
222222
registry: ${{ env.REGISTRY }} # using the registry environment variable
223223
username: ${{ github.actor }} # using the github.actor context
224224
password: ${{ secrets.GITHUB_TOKEN }} # using the GITHUB_TOKEN secret
225+
225226
- name: Build and push Docker image
226227
uses: docker/build-push-action@v4 # using the docker build and push action from the github marketplace - github.com/marketplace/actions/build-and-push-docker-images
227228
with:
228229
context: . # using the current directory as the context
229230
push: true # push the docker image to the registry
230-
tags: ghcr.io/${{ github.repository }}:${{ github.run_number }} # tag the docker image with the current run number from the github action workflow run
231-
cache-from: type=registry,ref=ghcr.io/${{ github.repository }}:$((${{ github.run_number }}-1))
231+
tags: ghcr.io/${{ github.repository }}:latest
232+
cache-from: type=registry,ref=ghcr.io/${{ github.repository }}:latest # use the docker layer caching to speed up the docker image build process
232233
cache-to: type=inline
233234

234235
runner-indexes: # job to generate the runner indexes for the uat-parallel-tests job

0 commit comments

Comments
 (0)