Skip to content

chore: release v0.7.8 #7

chore: release v0.7.8

chore: release v0.7.8 #7

Workflow file for this run

name: Publish Docker image
on:
push:
branches:
- master
release:
types: [published]
workflow_dispatch:
jobs:
push_to_registry:
name: Push Docker image to Docker Hub
runs-on: ubuntu-latest
steps:
- name: get_image_name
run: |
VERSION=$(echo "${{ github.ref }}" | sed -e 's,.*/\(.*\),\1,')
# Use Docker `latest` tag convention
[ "$VERSION" == "master" ] && VERSION=latest
repository=${{ github.repository }}
IMAGE_NAME=${{ secrets.DOCKER_USERNAME }}/home-page:$VERSION
echo IMAGE_NAME=$IMAGE_NAME
echo "IMAGE_NAME=$IMAGE_NAME" >> $GITHUB_ENV
- name: Check out the repo
uses: actions/checkout@v2
- name: Log in to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_TOKEN }}
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Push to Docker Hub
uses: docker/build-push-action@v4
with:
platforms: linux/amd64,linux/arm64
push: true
tags: ${{ env.IMAGE_NAME }}