Compare commits
21 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
96f1a40266
|
|||
|
959ba7d2d1
|
|||
|
c579fc95be
|
|||
|
d70aa85f99
|
|||
|
e5276053f2
|
|||
|
9f9386eba8
|
|||
|
1ff7d6b776
|
|||
|
9fd789bb6a
|
|||
|
043d4c0d5e
|
|||
|
59ba5a00e1
|
|||
|
50da145feb
|
|||
|
0b5943f792
|
|||
|
ba31c4f582
|
|||
|
370b875df1
|
|||
|
9393004434
|
|||
|
aec68c3ea5
|
|||
|
baad115f01
|
|||
|
09e1b2bcdc
|
|||
|
2ffe17ca60
|
|||
|
3596998f28
|
|||
|
2dc854c65a
|
@@ -6,31 +6,38 @@ on:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build-and-push:
|
build-and-push:
|
||||||
runs-on: ubuntu-latest
|
runs-on: docker-builder
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Set up QEMU
|
- name: Enable QEMU for multi-arch builds
|
||||||
uses: actions/setup-qemu-action@v3
|
run: |
|
||||||
|
docker run --privileged --rm tonistiigi/binfmt --install all
|
||||||
|
|
||||||
- name: Set up Docker Buildx
|
- name: Create and use Docker Buildx builder
|
||||||
uses: actions/setup-buildx-action@v3
|
run: |
|
||||||
|
docker buildx create --name miauinv-builder --use || docker buildx use miauinv-builder
|
||||||
|
docker buildx inspect --bootstrap
|
||||||
|
|
||||||
- name: Log in to Gitea Container Registry
|
- name: Log in to Gitea Container Registry
|
||||||
uses: docker/login-action@v3
|
run: |
|
||||||
with:
|
echo "${{ secrets.REGISTRY_TOKEN }}" | docker login git.miaurizius.de \
|
||||||
registry: git.miaurizius.de
|
--username "${{ secrets.REGISTRY_USER }}" \
|
||||||
username: ${{ gitea.actor }}
|
--password-stdin
|
||||||
password: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
|
|
||||||
- name: Build and push Docker image
|
- name: Prepare Docker image tags
|
||||||
uses: docker/build-push-action@v6
|
run: |
|
||||||
with:
|
IMAGE_REPO="$(echo "git.miaurizius.de/${{ gitea.repository }}" | tr '[:upper:]' '[:lower:]')"
|
||||||
context: .
|
echo "IMAGE_REPO=$IMAGE_REPO" >> "$GITHUB_ENV"
|
||||||
file: ./Dockerfile
|
|
||||||
push: true
|
- name: Build and push multi-arch Docker image
|
||||||
platforms: linux/amd64,linux/arm64
|
run: |
|
||||||
tags: |
|
docker buildx build \
|
||||||
git.miaurizius.de/${{ gitea.repository }}:latest
|
--platform linux/amd64,linux/arm64 \
|
||||||
git.miaurizius.de/${{ gitea.repository }}:${{ gitea.event.release.tag_name }}
|
--file ./Dockerfile \
|
||||||
|
--tag "$IMAGE_REPO:latest" \
|
||||||
|
--tag "$IMAGE_REPO:${{ gitea.event.release.tag_name }}" \
|
||||||
|
--push \
|
||||||
|
.
|
||||||
Reference in New Issue
Block a user