Skip to content

Commit

Permalink
docker wip
Browse files Browse the repository at this point in the history
  • Loading branch information
steebchen committed Sep 19, 2024
1 parent 48c8e0a commit d9c53d1
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions .github/workflows/preview.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,16 +42,18 @@ jobs:
- name: Build binaries
run: |
docker build -t build -f .github/Dockerfile .
docker run --rm -v "$(pwd)/artifacts:/artifacts" build /bin/sh -c "cp -r /app/artifacts/* /artifacts"
docker buildx build -t build -f .github/Dockerfile . \
--cache-from type=local,src=/tmp/.buildx-cache \
--cache-to type=local,dest=/tmp/.buildx-cache-new,mode=max
docker run --rm -v "$(pwd)/artifacts:/artifacts" build /bin/sh -c "cp -r /app/artifacts/* /artifacts"
- name: Build and push docker image
uses: docker/build-push-action@v3
with:
push: true
tags: ghcr.io/${{ github.repository }}:preview--${{ steps.vars.outputs.sha_short }}
cache-from: type=local,src=/tmp/.buildx-cache
cache-to: type=local,dest=/tmp/.buildx-cache-new
cache-to: type=local,dest=/tmp/.buildx-cache-new,mode=max
platforms: linux/amd64
build-contexts: |
artifacts=artifacts

0 comments on commit d9c53d1

Please sign in to comment.