1
0
mirror of https://github.com/donaldzou/WGDashboard.git synced 2024-11-22 23:27:45 +01:00
WGDashboard/.github/workflows/docker-build.yaml

45 lines
1.1 KiB
YAML
Raw Normal View History

2024-10-17 12:52:34 +02:00
name: Docker-Build
on:
2024-11-01 09:19:47 +01:00
push:
branches: [ main ]
2024-10-17 12:52:34 +02:00
workflow_dispatch:
inputs:
trigger-build:
description: 'Trigger a manual build and push'
default: 'true'
env:
DOCKER_IMAGE: donaldzou/wgdashboard
2024-10-17 12:52:34 +02:00
jobs:
docker_build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
with:
platforms: linux/amd64,linux/arm64,linux/arm/v6,linux/arm/v7
2024-10-17 12:52:34 +02:00
- name: Log in to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_HUB_USERNAME }}
password: ${{ secrets.DOCKER_HUB_PASSWORD }}
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
2024-11-15 12:08:51 +01:00
- name: Build and export (multi-arch)
2024-10-17 12:52:34 +02:00
uses: docker/build-push-action@v6
with:
context: .
push: true
tags: ${{ env.DOCKER_IMAGE }}:latest
platforms: linux/amd64,linux/arm64,linux/arm/v6,linux/arm/v7