Skip to content

name docker image based on pushed tag #2

name docker image based on pushed tag

name docker image based on pushed tag #2

Workflow file for this run

name: Biuld Docker Image for Every Tag
on:
push:
tags:
- '**'
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout Version
uses: actions/checkout@v4
- name: Dump tag name
run: echo "Building tag ${{github.ref_name}}"
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to DockerHub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push Docker image
uses: docker/build-push-action@v5
with:
context: .
platforms: linux/amd64,linux/arm64
push: true
tags: mcsystems/news-search-api:${{github.ref_name}}