forked from idrl/idrlnet
update docker.yml
This commit is contained in:
parent
68525c5ef5
commit
2f76e62821
|
@ -2,8 +2,11 @@ name: docker-build-push
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches:
|
pull_request:
|
||||||
- 'dev'
|
branches: [master]
|
||||||
|
release:
|
||||||
|
types: [published, created, edited]
|
||||||
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
docker:
|
docker:
|
||||||
|
@ -30,4 +33,18 @@ jobs:
|
||||||
tags: ${{ secrets.DOCKERHUB_USERNAME }}/idrlnet:latest
|
tags: ${{ secrets.DOCKERHUB_USERNAME }}/idrlnet:latest
|
||||||
-
|
-
|
||||||
name: Image digest
|
name: Image digest
|
||||||
run: echo ${{ steps.docker_build.outputs.digest }}
|
run: echo ${{ steps.docker_build.outputs.digest }}
|
||||||
|
|
||||||
|
-
|
||||||
|
name: Get release version
|
||||||
|
if: github.event_name == 'release'
|
||||||
|
id: get_version
|
||||||
|
run: echo "::set-output name=RELEASE_VERSION::${{ github.event.release.tag_name }}"
|
||||||
|
|
||||||
|
-
|
||||||
|
name: Publish Releases to Dockerhub
|
||||||
|
if: github.event_name == 'release'
|
||||||
|
uses: docker/build-push-action@v2
|
||||||
|
with:
|
||||||
|
push: true
|
||||||
|
tags: ${{ secrets.DOCKERHUB_USERNAME }}/idrlnet:${{ steps.get_version.outputs.RELEASE_VERSION }}
|
||||||
|
|
Loading…
Reference in New Issue