Skip to content

Workflow file for this run

name: Docker Image Release
on:
release:
types: [published]
jobs:
build-and-release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Build the Docker image
run: docker build . --file Dockerfile --tag topheee/postfix-courier-mail:${{ github.event.release.name }}
- name: Login to Docker Hub
run: echo "${{ secrets.DOCKER_HUB_TOKEN }}" | docker login -u "${{ secrets.DOCKER_HUB_USER }}" --password-stdin
- name: Push the Docker image
run: docker push topheee/postfix-courier-mail:${{ github.event.release.name }}
- name: Logout of Docker Hub
run: docker logout