Skip to content

Release

Release #18

Workflow file for this run

name: Release
on:
release:
types: [published]
env:
DOCKER_BUILDKIT: 0
jobs:
publish_docker_image:
timeout-minutes: 30
environment: Release
name: Push Docker image to Docker Hub
runs-on: ubuntu-latest
steps:
- name: Check out the repo
uses: actions/checkout@v4
- name: Log in to Docker Hub
uses: docker/login-action@343f7c4344506bcbf9b4de18042ae17996df046d # v3.0.0
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Build and push image (amd64)
run: |
docker build --no-cache -f ./amd64.Dockerfile -t infocus7/trendgenie:latest-amd64 .
docker push infocus7/trendgenie:latest-amd64
- name: Build and push image (arm64)
run:
docker build --no-cache -f ./Dockerfile -t infocus7/trendgenie:latest-arm64 .
docker push infocus7/trendgenie:latest-arm64
- name: Create and push manifest
run: |
docker manifest create infocus7/trendgenie:latest --amend infocus7/trendgenie:latest-amd64 --amend infocus7/trendgenie:latest-arm64
docker manifest push infocus7/trendgenie:latest
docker manifest create infocus7/trendgenie:${{ github.event.release.tag_name }} --amend infocus7/trendgenie:latest-amd64 --amend infocus7/trendgenie:latest-arm64
docker manifest push infocus7/trendgenie:${{ github.event.release.tag_name }}