Skip to content

Commit

Permalink
Set build only on created release type
Browse files Browse the repository at this point in the history
  • Loading branch information
srisco committed Jun 17, 2020
1 parent 8399946 commit 9dab5a7
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
push:
branches: [master]
release:
types: [created]

jobs:
buildx:
Expand All @@ -23,7 +24,7 @@ jobs:
fi
TAGS="--tag ${DOCKER_IMAGE}:latest"
if [[ -z $VERSION ]]; then
if [[ ! -v $VERSION ]]; then
TAGS="$TAGS --tag ${DOCKER_IMAGE}:${VERSION}"
fi
Expand All @@ -32,7 +33,7 @@ jobs:
echo ::set-output name=buildx_args::--platform ${DOCKER_PLATFORMS} \
--build-arg VERSION=${VERSION} \
--build-arg GIT_COMMIT=${GITHUB_SHA::8} \
${TAGS} .
${TAGS} --file Dockerfile .
- name: Set up Docker Buildx
uses: crazy-max/[email protected]
Expand Down

0 comments on commit 9dab5a7

Please sign in to comment.