Publish Docker image #257
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This workflow uses actions that are not certified by GitHub. | |
# They are provided by a third-party and are governed by | |
# separate terms of service, privacy policy, and support | |
# documentation. | |
name: Publish Docker image | |
on: | |
workflow_run: | |
workflows: [CI] | |
types: [completed] | |
branches: [v3] | |
jobs: | |
push_to_registry: | |
name: Push Docker image to Docker Hub | |
runs-on: ubuntu-latest | |
# Check if the tests were successful and were launched by a push event | |
if: ${{ github.event.workflow_run.conclusion == 'success' && github.event.workflow_run.event == 'push' }} | |
steps: | |
- name: Log in to Docker Hub | |
uses: docker/login-action@v2 | |
with: | |
username: ewjoachim | |
password: ${{ secrets.DOCKER_PASSWORD }} | |
- name: Build and push Docker image | |
uses: docker/build-push-action@v4 | |
with: | |
# See Dockerfile.build for instructions on bumping this. | |
tags: ewjoachim/python-coverage-comment-action-base:v1 | |
push: true | |
file: Dockerfile.build |