Merge pull request 'bugfix/15-docker-deployment' (#18) from bugfix/15-docker-deployment into main
Reviewed-on: #18
This commit is contained in:
@@ -6,33 +6,30 @@ on:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build-and-push:
|
build-and-push:
|
||||||
runs-on: docker-builder
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Enable QEMU for multi-arch builds
|
- name: Set up QEMU
|
||||||
run: |
|
uses: actions/setup-qemu-action@v3
|
||||||
docker run --privileged --rm tonistiigi/binfmt --install all
|
|
||||||
|
|
||||||
- name: Create and use Docker Buildx builder
|
- name: Set up Docker Buildx
|
||||||
run: |
|
uses: actions/setup-buildx-action@v3
|
||||||
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
|
||||||
run: |
|
run: |
|
||||||
echo "${{ secrets.GITHUB_TOKEN }}" | docker login git.miaurizius.de \
|
echo "${{ secrets.REGISTRY_TOKEN }}" | docker login git.miaurizius.de \
|
||||||
--username "${{ gitea.actor }}" \
|
--username "${{ secrets.REGISTRY_USER }}" \
|
||||||
--password-stdin
|
--password-stdin
|
||||||
|
|
||||||
- name: Build and push multi-arch Docker image
|
- name: Build and push Docker image
|
||||||
run: |
|
uses: docker/build-push-action@v6
|
||||||
docker buildx build \
|
with:
|
||||||
--platform linux/amd64,linux/arm64 \
|
context: .
|
||||||
--file ./Dockerfile \
|
file: ./Dockerfile
|
||||||
--tag git.miaurizius.de/${{ gitea.repository }}:latest \
|
push: true
|
||||||
--tag git.miaurizius.de/${{ gitea.repository }}:${{ gitea.event.release.tag_name }} \
|
platforms: linux/amd64,linux/arm64
|
||||||
--push \
|
tags: |
|
||||||
.
|
git.miaurizius.de/${{ gitea.repository }}:latest
|
||||||
|
git.miaurizius.de/${{ gitea.repository }}:${{ gitea.event.release.tag_name }}
|
||||||
Reference in New Issue
Block a user