Try to build separate
Some checks failed
Build Docker Image / Build AMD64 (3.10) (push) Failing after 27s
Build Docker Image / Build AMD64 (3.11) (push) Failing after 28s
Build Docker Image / Build AMD64 (3.13) (push) Has been cancelled
Build Docker Image / Build ARM64 (3.13) (push) Has been cancelled
Build Docker Image / Build AMD64 (3.12) (push) Has been cancelled
Build Docker Image / Create Multi-arch Manifest (3.10) (push) Has been cancelled
Build Docker Image / Create Multi-arch Manifest (3.11) (push) Has been cancelled
Build Docker Image / Create Multi-arch Manifest (3.12) (push) Has been cancelled
Build Docker Image / Create Multi-arch Manifest (3.13) (push) Has been cancelled
Build Docker Image / Build ARM64 (3.11) (push) Has been cancelled
Build Docker Image / Build ARM64 (3.10) (push) Has been cancelled
Build Docker Image / Build ARM64 (3.12) (push) Has been cancelled

This commit is contained in:
2024-12-08 13:54:01 +02:00
parent bd08d0e55b
commit bd7cfc17a2

View File

@@ -8,34 +8,27 @@ on:
- cron: '@monthly' - cron: '@monthly'
jobs: jobs:
build-and-push-image: build-amd64:
runs-on: linux_amd runs-on: linux_amd
name: Build and Push name: Build AMD64
container: container:
image: catthehacker/ubuntu:act-latest image: catthehacker/ubuntu:act-latest
env: env:
DOCKER_ORG: technocloud-public DOCKER_ORG: technocloud-public
RUNNER_TOOL_CACHE: /toolcache RUNNER_TOOL_CACHE: /toolcache
strategy: strategy:
matrix: matrix:
python-version: ['3.10', '3.11', '3.12', '3.13'] python-version: ['3.10', '3.11', '3.12', '3.13']
steps: steps:
- name: Checkout - name: Checkout
uses: actions/checkout@v4 uses: actions/checkout@v4
with: with:
github-server-url: https://gitea.technocloud.ee github-server-url: https://gitea.technocloud.ee
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker BuildX - name: Set up Docker BuildX
uses: docker/setup-buildx-action@v3 uses: docker/setup-buildx-action@v3
with: with:
platforms: linux/amd64,linux/arm64 platforms: linux/amd64
driver-opts: | driver-opts: |
max-concurrent=1 max-concurrent=1
@@ -51,11 +44,86 @@ jobs:
run: | run: |
echo REPO_NAME=$(echo ${GITHUB_REPOSITORY} | awk -F"/" '{print $2}') >> $GITHUB_OUTPUT echo REPO_NAME=$(echo ${GITHUB_REPOSITORY} | awk -F"/" '{print $2}') >> $GITHUB_OUTPUT
- name: Build and Push - name: Build and Push AMD64
uses: docker/build-push-action@v5 uses: docker/build-push-action@v5
with: with:
context: . context: .
file: Dockerfile.python${{ matrix.python-version }} file: Dockerfile.python${{ matrix.python-version }}
platforms: linux/amd64,linux/arm64 platforms: linux/amd64
push: true push: true
tags: gitea.technocloud.ee/${{ env.DOCKER_ORG }}/${{ steps.meta.outputs.REPO_NAME }}:python${{ matrix.python-version }} tags: gitea.technocloud.ee/${{ env.DOCKER_ORG }}/${{ steps.meta.outputs.REPO_NAME }}:python${{ matrix.python-version }}-amd64
build-arm64:
runs-on: ubuntu-latest
name: Build ARM64
container:
image: catthehacker/ubuntu:act-latest
env:
DOCKER_ORG: technocloud-public
RUNNER_TOOL_CACHE: /toolcache
strategy:
matrix:
python-version: ['3.10', '3.11', '3.12', '3.13']
steps:
- name: Checkout
uses: actions/checkout@v4
with:
github-server-url: https://gitea.technocloud.ee
- name: Set up Docker BuildX
uses: docker/setup-buildx-action@v3
with:
platforms: linux/arm64
- name: Login to DockerHub
uses: docker/login-action@v3
with:
registry: gitea.technocloud.ee
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Get Meta
id: meta
run: |
echo REPO_NAME=$(echo ${GITHUB_REPOSITORY} | awk -F"/" '{print $2}') >> $GITHUB_OUTPUT
- name: Build and Push ARM64
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.python${{ matrix.python-version }}
platforms: linux/arm64
push: true
tags: gitea.technocloud.ee/${{ env.DOCKER_ORG }}/${{ steps.meta.outputs.REPO_NAME }}:python${{ matrix.python-version }}-arm64
create-manifest:
needs: [build-amd64, build-arm64]
runs-on: linux_amd
name: Create Multi-arch Manifest
container:
image: catthehacker/ubuntu:act-latest
env:
DOCKER_ORG: technocloud-public
strategy:
matrix:
python-version: ['3.10', '3.11', '3.12', '3.13']
steps:
- name: Login to DockerHub
uses: docker/login-action@v3
with:
registry: gitea.technocloud.ee
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Get Meta
id: meta
run: |
echo REPO_NAME=$(echo ${GITHUB_REPOSITORY} | awk -F"/" '{print $2}') >> $GITHUB_OUTPUT
- name: Create and Push Manifest
run: |
docker manifest create \
gitea.technocloud.ee/${{ env.DOCKER_ORG }}/${{ steps.meta.outputs.REPO_NAME }}:python${{ matrix.python-version }} \
gitea.technocloud.ee/${{ env.DOCKER_ORG }}/${{ steps.meta.outputs.REPO_NAME }}:python${{ matrix.python-version }}-amd64 \
gitea.technocloud.ee/${{ env.DOCKER_ORG }}/${{ steps.meta.outputs.REPO_NAME }}:python${{ matrix.python-version }}-arm64
docker manifest push gitea.technocloud.ee/${{ env.DOCKER_ORG }}/${{ steps.meta.outputs.REPO_NAME }}:python${{ matrix.python-version }}