diff --git a/.github/workflows/docker-publish.yml b/.github/workflows/docker-publish.yml index 68e8527..52180cb 100644 --- a/.github/workflows/docker-publish.yml +++ b/.github/workflows/docker-publish.yml @@ -43,14 +43,17 @@ jobs: username: ${{ github.actor }} password: ${{ secrets.GITHUB_TOKEN }} + - name: Docker meta + id: meta + uses: docker/metadata-action@v4 + with: + images: ghcr.io/${{ github.repository }} + tags: latest + # Build and push Docker image with Buildx (don't push on PR) # https://github.com/docker/build-push-action - - name: Build and push Docker image - id: build-and-push + - name: Build and push uses: docker/build-push-action@v5 with: - context: . - push: ${{ github.event_name != 'pull_request' }} - cache-from: type=gha - cache-to: type=gha,mode=max - tags: molssi-education/molssi-python-best-practices:latest + push: true + tags: ${{ steps.meta.outputs.tags }}