Skip to content
This repository has been archived by the owner on Aug 14, 2024. It is now read-only.

Build

Build #9

Workflow file for this run

name: Build
on:
release:
types: [published]
jobs:
docker-build:
runs-on: ubuntu-latest
name: Docker build
steps:
- uses: actions/checkout@v3
- name: Get the tag name
id: get_tag_name
run: echo "tag=${GITHUB_REF/refs\/tags\//}" >> $GITHUB_OUTPUT
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Login to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Build Azure Billing Exporter docker image
uses: docker/build-push-action@v4
with:
context: .
tags: dodopizza/azure_billing_exporter:${{ steps.get_tag_name.outputs.tag }}
push: ${{ startsWith(github.ref, 'refs/tags/') }}