Skip to content

Commit

Permalink
Add docker-publish workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
Carlgo11 committed Aug 11, 2021
1 parent cbacf34 commit 7b7c925
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions .github/workflows/docker-publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Docker Push
on:
release:
types: published
jobs:
Build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: crazy-max/ghaction-docker-buildx@v3
with:
buildx-version: latest
qemu-version: latest
- name: Docker build
run: |
echo "${{ secrets.DOCKER }}" | docker login --username carlgo11 --password-stdin
docker buildx create --use
VERSION=$(echo "${{ github.ref }}" | sed -e 's,.*/\(.*\),\1,')
# Strip "v" prefix from tag name
[[ "${{ github.ref }}" == "refs/tags/"* ]] && VERSION=$(echo $VERSION | sed -e 's/^v//')
echo VERSION=$VERSION
docker buildx build --platform linux/amd64,linux/arm/v7,linux/arm64 --rm --tag carlgo11/guest-portal:latest --tag carlgo11/tempfiles-backend:$VERSION --push --compress .

0 comments on commit 7b7c925

Please sign in to comment.