Leverage forgejo actions
This commit is contained in:
parent
d01cb87a5c
commit
162b09a934
1 changed files with 37 additions and 0 deletions
37
.forgejo/workflows/docker-build.yaml
Normal file
37
.forgejo/workflows/docker-build.yaml
Normal file
|
@ -0,0 +1,37 @@
|
||||||
|
name: ci
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
builder:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Check out code
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
|
- name: Set up QEMU
|
||||||
|
uses: docker/setup-qemu-action@v2
|
||||||
|
|
||||||
|
- name: Set up context for Docker Buildx
|
||||||
|
run: docker context create builders
|
||||||
|
|
||||||
|
- name: Set up Docker Build
|
||||||
|
uses: docker/setup-buildx-action@v2
|
||||||
|
with:
|
||||||
|
version: latest
|
||||||
|
endpoint: builders
|
||||||
|
|
||||||
|
- name: Login to Docker Registry
|
||||||
|
uses: docker/login-action@v3
|
||||||
|
with:
|
||||||
|
registry: ${{ vars.REGISTRY_URL }}
|
||||||
|
username: ${{ secrets.REGISTRY_USERNAME }}
|
||||||
|
password: ${{ secrets.REGISTRY_TOKEN }}
|
||||||
|
|
||||||
|
- name: Build and push
|
||||||
|
uses: docker/build-push-action@v6
|
||||||
|
with:
|
||||||
|
push: true
|
||||||
|
platforms: linux/amd64,linux/arm64
|
||||||
|
tags: ${{ vars.REGISTRY_URL }}/${{ env.GITHUB_REPOSITORY }}:latest
|
Loading…
Reference in a new issue