Skip to content

Refactor config and get rid of some dependencies #5

Refactor config and get rid of some dependencies

Refactor config and get rid of some dependencies #5

Workflow file for this run

name: build docker image
on:
push:
tags:
- 'v[0-9]+.[0-9]+.[0-9]+' # Push events to matching v*, i.e. v1.0.0, v20.15.0
jobs:
build:
name: build-docker-image
runs-on: ubuntu-latest
steps:
- name: Prepare
run: |
tag=$(echo "${{ github.ref }}" | cut -d "/" -f3)
echo "NEW_TAG=${tag}" >> $GITHUB_ENV
- name: Checkout code
uses: actions/checkout@v4
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
id: buildx
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Build and push
uses: docker/build-push-action@v6
with:
context: .
platforms: linux/amd64,linux/arm/v7,linux/arm64
push: true
tags: torilabs/ipsec-prometheus-exporter:latest,torilabs/ipsec-prometheus-exporter:${{ env.NEW_TAG }}