From f9c6a34b2d53f7242578ff2ab5b83933b44dc6f7 Mon Sep 17 00:00:00 2001 From: Marco Acierno Date: Sun, 5 Jan 2025 15:25:57 +0100 Subject: [PATCH 1/9] Separate Pretix ARM base build in it is own workflow --- .github/workflows/build-base-pretix.yml | 41 +++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 .github/workflows/build-base-pretix.yml diff --git a/.github/workflows/build-base-pretix.yml b/.github/workflows/build-base-pretix.yml new file mode 100644 index 0000000000..ddb9423d3e --- /dev/null +++ b/.github/workflows/build-base-pretix.yml @@ -0,0 +1,41 @@ +name: Build base pretix image + +concurrency: ${{ inputs.version }} + +on: + workflow_dispatch: + inputs: + version: + description: 'The version of pretix to build. Example: v2024.10.0' + required: true + type: string + +jobs: + build: + name: Build + runs-on: [self-hosted] + permissions: + contents: read + packages: write + steps: + - uses: actions/checkout@v4 + with: + repository: pretix/pretix + ref: ${{ inputs.version }} + - name: Login to Amazon ECR + uses: aws-actions/amazon-ecr-login@v2 + - name: Set up Docker Buildx + id: buildx + uses: docker/setup-buildx-action@v3 + - name: Build pretix base + uses: docker/build-push-action@v6 + id: build-pretix-base + with: + file: ./Dockerfile + builder: ${{ steps.buildx.outputs.name }} + provenance: false + push: true + tags: ghcr.io/pythonitalia/pycon/arm-pretix:${{ inputs.version }} + cache-from: type=local,src=/tmp/.buildx-cache + cache-to: type=local,dest=/tmp/.buildx-cache + platforms: linux/arm64 From 529937317284e47d5a4504a66599eb1f890e9682 Mon Sep 17 00:00:00 2001 From: Marco Acierno Date: Sun, 5 Jan 2025 15:26:32 +0100 Subject: [PATCH 2/9] Remove ECR login --- .github/workflows/build-base-pretix.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/build-base-pretix.yml b/.github/workflows/build-base-pretix.yml index ddb9423d3e..3556ee5e89 100644 --- a/.github/workflows/build-base-pretix.yml +++ b/.github/workflows/build-base-pretix.yml @@ -22,8 +22,6 @@ jobs: with: repository: pretix/pretix ref: ${{ inputs.version }} - - name: Login to Amazon ECR - uses: aws-actions/amazon-ecr-login@v2 - name: Set up Docker Buildx id: buildx uses: docker/setup-buildx-action@v3 From 39e0981dfdf766f593e028b10274a9e7c4c83d6e Mon Sep 17 00:00:00 2001 From: Marco Acierno Date: Sun, 5 Jan 2025 15:27:07 +0100 Subject: [PATCH 3/9] test --- .github/workflows/build-base-pretix.yml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-base-pretix.yml b/.github/workflows/build-base-pretix.yml index 3556ee5e89..9f537e430b 100644 --- a/.github/workflows/build-base-pretix.yml +++ b/.github/workflows/build-base-pretix.yml @@ -1,8 +1,9 @@ name: Build base pretix image -concurrency: ${{ inputs.version }} +concurrency: v2024.11.0 on: + pull_request: workflow_dispatch: inputs: version: @@ -21,7 +22,7 @@ jobs: - uses: actions/checkout@v4 with: repository: pretix/pretix - ref: ${{ inputs.version }} + ref: v2024.11.0 - name: Set up Docker Buildx id: buildx uses: docker/setup-buildx-action@v3 @@ -33,7 +34,7 @@ jobs: builder: ${{ steps.buildx.outputs.name }} provenance: false push: true - tags: ghcr.io/pythonitalia/pycon/arm-pretix:${{ inputs.version }} + tags: ghcr.io/pythonitalia/pycon/arm-pretix:v2024.11.0 cache-from: type=local,src=/tmp/.buildx-cache cache-to: type=local,dest=/tmp/.buildx-cache platforms: linux/arm64 From 5c12451597973296e74ab0d5e6d7c1611876868b Mon Sep 17 00:00:00 2001 From: Marco Acierno Date: Sun, 5 Jan 2025 15:29:09 +0100 Subject: [PATCH 4/9] change --- .github/workflows/build-base-pretix.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build-base-pretix.yml b/.github/workflows/build-base-pretix.yml index 9f537e430b..af7206d8bf 100644 --- a/.github/workflows/build-base-pretix.yml +++ b/.github/workflows/build-base-pretix.yml @@ -26,6 +26,7 @@ jobs: - name: Set up Docker Buildx id: buildx uses: docker/setup-buildx-action@v3 + - run: ls -la - name: Build pretix base uses: docker/build-push-action@v6 id: build-pretix-base From fd51cc5614b6cc69172a78a99525cd5f446b3d56 Mon Sep 17 00:00:00 2001 From: Marco Acierno Date: Sun, 5 Jan 2025 15:29:58 +0100 Subject: [PATCH 5/9] change --- .github/workflows/build-base-pretix.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/build-base-pretix.yml b/.github/workflows/build-base-pretix.yml index af7206d8bf..a894bb52a3 100644 --- a/.github/workflows/build-base-pretix.yml +++ b/.github/workflows/build-base-pretix.yml @@ -31,7 +31,6 @@ jobs: uses: docker/build-push-action@v6 id: build-pretix-base with: - file: ./Dockerfile builder: ${{ steps.buildx.outputs.name }} provenance: false push: true From bb00c82dc7c9bb59146cad6d4f6d51c82e6fd8a0 Mon Sep 17 00:00:00 2001 From: Marco Acierno Date: Sun, 5 Jan 2025 15:30:55 +0100 Subject: [PATCH 6/9] change --- .github/workflows/build-base-pretix.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build-base-pretix.yml b/.github/workflows/build-base-pretix.yml index a894bb52a3..8dab99a7aa 100644 --- a/.github/workflows/build-base-pretix.yml +++ b/.github/workflows/build-base-pretix.yml @@ -31,6 +31,7 @@ jobs: uses: docker/build-push-action@v6 id: build-pretix-base with: + context: . builder: ${{ steps.buildx.outputs.name }} provenance: false push: true From 697a9e0eee8f53cbceb49cd426d6773bb7c768d0 Mon Sep 17 00:00:00 2001 From: Marco Acierno Date: Sun, 5 Jan 2025 15:53:07 +0100 Subject: [PATCH 7/9] change --- .github/workflows/build-base-pretix.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/build-base-pretix.yml b/.github/workflows/build-base-pretix.yml index 8dab99a7aa..97d2e2133d 100644 --- a/.github/workflows/build-base-pretix.yml +++ b/.github/workflows/build-base-pretix.yml @@ -19,6 +19,12 @@ jobs: contents: read packages: write steps: + - name: Log in to the Container registry + uses: docker/login-action@v3 + with: + registry: ghcr.io + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} - uses: actions/checkout@v4 with: repository: pretix/pretix From c00ead57e764cf62610731457121cfce526e7602 Mon Sep 17 00:00:00 2001 From: Marco Acierno Date: Sun, 5 Jan 2025 16:01:22 +0100 Subject: [PATCH 8/9] update --- .github/workflows/build-base-pretix.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/build-base-pretix.yml b/.github/workflows/build-base-pretix.yml index 97d2e2133d..4d7a93f0a5 100644 --- a/.github/workflows/build-base-pretix.yml +++ b/.github/workflows/build-base-pretix.yml @@ -3,7 +3,6 @@ name: Build base pretix image concurrency: v2024.11.0 on: - pull_request: workflow_dispatch: inputs: version: @@ -32,7 +31,6 @@ jobs: - name: Set up Docker Buildx id: buildx uses: docker/setup-buildx-action@v3 - - run: ls -la - name: Build pretix base uses: docker/build-push-action@v6 id: build-pretix-base From fc3b94841ad7c338f45be29778006e8111be2146 Mon Sep 17 00:00:00 2001 From: Marco Acierno Date: Sun, 5 Jan 2025 16:04:09 +0100 Subject: [PATCH 9/9] version --- .github/workflows/build-base-pretix.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-base-pretix.yml b/.github/workflows/build-base-pretix.yml index 4d7a93f0a5..0cd01282f2 100644 --- a/.github/workflows/build-base-pretix.yml +++ b/.github/workflows/build-base-pretix.yml @@ -1,6 +1,6 @@ name: Build base pretix image -concurrency: v2024.11.0 +concurrency: ${{ inputs.version }} on: workflow_dispatch: @@ -27,7 +27,7 @@ jobs: - uses: actions/checkout@v4 with: repository: pretix/pretix - ref: v2024.11.0 + ref: ${{ inputs.version }} - name: Set up Docker Buildx id: buildx uses: docker/setup-buildx-action@v3 @@ -39,7 +39,7 @@ jobs: builder: ${{ steps.buildx.outputs.name }} provenance: false push: true - tags: ghcr.io/pythonitalia/pycon/arm-pretix:v2024.11.0 + tags: ghcr.io/pythonitalia/pycon/arm-pretix:${{ inputs.version }} cache-from: type=local,src=/tmp/.buildx-cache cache-to: type=local,dest=/tmp/.buildx-cache platforms: linux/arm64