3737 - name : Check out the repo
3838 uses : actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
3939
40- - name : Set up Docker Buildx
41- uses : docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435 # v3.11.1
42-
4340 - name : Log in to Docker Hub
4441 uses : docker/login-action@184bdaa0721073962dff0199f1fb9940f07167d1 # v3.5.0
4542 with :
@@ -53,25 +50,17 @@ jobs:
5350 username : ${{ github.actor }}
5451 password : ${{ secrets.GITHUB_TOKEN }}
5552
56- - name : Extract metadata (tags, labels) for Docker
57- id : meta
58- uses : docker/metadata-action@c1e51972afc2121e065aed6d45c65596fe445f3f # v5.8.0
59- with :
60- images : elementsinteractive/twyn
61-
6253 - name : Build and push Docker image
63- uses : docker/build-push-action@ca052bb54ab0790a636c9b5f226502c73d547a25 # v5.4.0
54+ uses : ./.github/actions/docker-build
6455 with :
65- context : .
66- file : ./Dockerfile
67- push : true
56+ push-image : " true"
6857 platforms : linux/amd64,linux/arm64
69- tags : ${{ steps.meta.outputs.tags }}
70- labels : ${{ steps.meta.outputs.labels }}
71- cache-from : |
72- type=registry,ref=ghcr.io/elementsinteractive/twyn:buildcache
73- cache-to : |
74- type=registry,ref=ghcr.io/elementsinteractive/twyn:buildcache,mode=max,compression=zstd,force-compression=true,oci-mediatypes=true
58+ dockerfile : ./Dockerfile
59+ context : .
60+ image-name : elementsinteractive/twyn
61+ cache-from : type=registry,ref=ghcr.io/elementsinteractive/twyn:buildcache
62+ cache-to : type=registry,ref=ghcr.io/elementsinteractive/twyn:buildcache,mode=max,compression=zstd,force-compression=true,oci-mediatypes=true
63+
7564 - name : Delete old cache entries
7665 env :
7766 GH_TOKEN : ${{ github.token }}
0 commit comments