diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index 6c982ef..491868f 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -2,8 +2,13 @@ name: Publish Docker image on: workflow_dispatch: push: + branches: + - master tags: - 'v*' + pull_request: + branches: + - 'master' jobs: push_to_registry: name: Push Docker image to Docker Hub @@ -13,13 +18,10 @@ jobs: uses: actions/checkout@v2 - name: Docker meta - id: docker_meta - uses: crazy-max/ghaction-docker-meta@v1 + id: meta + uses: docker/metadata-action@v4 with: images: crackair/xrayr - tag-semver: | - {{version}} - {{major}}.{{minor}} - name: Set up Docker Buildx uses: docker/setup-buildx-action@v1 @@ -36,5 +38,5 @@ jobs: context: . platforms: linux/arm/v7,linux/arm64,linux/amd64,linux/s390x push: ${{ github.event_name != 'pull_request' }} - tags: ${{ steps.docker_meta.outputs.tags }} - labels: ${{ steps.docker_meta.outputs.labels }} \ No newline at end of file + tags: ${{ steps.meta.outputs.tags }} + labels: ${{ steps.meta.outputs.labels }} \ No newline at end of file