http3-ytproxy/.forgejo/workflows/ci.yml
Fijxu 7ee6480b2f
All checks were successful
CI / build (push) Successful in 6m7s
v2
2024-10-29 15:57:08 -03:00

76 lines
2.3 KiB
YAML

name: "CI"
on:
workflow_dispatch:
inputs: {}
push:
branches: ["*"]
jobs:
build:
runs-on: runner
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Set up QEMU for ARM64 builds
uses: docker/setup-qemu-action@v3
with:
platforms: arm64
- name: Setup Docker BuildX system
uses: docker/setup-buildx-action@v3
- name: Login to Docker Container Registry (git.nadeko.net)
uses: docker/login-action@v3
with:
registry: git.nadeko.net
username: ${{ secrets.USERNAME }}
password: ${{ secrets.TOKEN }}
- name: Docker meta AMD64
id: meta
uses: docker/metadata-action@v5
with:
images: git.nadeko.net/fijxu/http3-ytproxy
tags: |
type=sha,format=short,prefix={{date 'YYYY.MM.DD'}}-,enable=${{ github.ref == format('refs/heads/{0}', 'main') }}
type=raw,value=latest,enable=${{ github.ref == format('refs/heads/{0}', 'main') }}
- name: Build and push Docker AMD64 image
uses: docker/build-push-action@v5
with:
context: .
platforms: linux/amd64
# labels: ${{ steps.meta.outputs.labels }}
push: true
tags: ${{ steps.meta.outputs.tags }}
- name: Docker meta ARM64
id: meta-arm64
uses: docker/metadata-action@v5
with:
images: git.nadeko.net/fijxu/http3-ytproxy
flavor: |
suffix=-arm64
tags: |
type=sha,format=short,prefix={{date 'YYYY.MM.DD'}}-,enable=${{ github.ref == format('refs/heads/{0}', 'main') }}
type=raw,value=master,enable=${{ github.ref == format('refs/heads/{0}', 'main') }}
- name: Build and push Docker ARM64
uses: docker/build-push-action@v5
with:
context: .
platforms: linux/arm64/v8
# labels: ${{ steps.meta-arm64.outputs.labels }}
push: true
tags: ${{ steps.meta-arm64.outputs.tags }}
# - name: Build images
# uses: https://code.forgejo.org/docker/build-push-action@v5
# with:
# context: .
# tags: git.nadeko.net/fijxu/http3-ytproxy:latest
# platforms: linux/amd64,linux/arm64/v8
# push: true