tdd-platform: drop poetry export step #649
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI/CD | |
| on: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| workflow_dispatch: | |
| inputs: | |
| image_tag: | |
| description: Image(s) and tag to be rebuilt as '<container>:<tag>[,...]'. | |
| type: string | |
| required: true | |
| permissions: | |
| contents: read | |
| packages: write | |
| security-events: write | |
| jobs: | |
| collect: | |
| name: Collect Matrix Jobs | |
| runs-on: ubuntu-22.04 | |
| outputs: | |
| builderMatrixStage1: ${{steps.collect.outputs.builderMatrixStage1}} | |
| builderMatrixStage2: ${{steps.collect.outputs.builderMatrixStage2}} | |
| builderMatrixStage3: ${{steps.collect.outputs.builderMatrixStage3}} | |
| steps: | |
| - name: Checkout Repository | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| - name: Detect changes and build GHA matrices | |
| id: collect | |
| run: .github/workflows/collect.py ${{inputs.image_tag}} | |
| stage1: | |
| name: Build Stage 1 Images | |
| needs: collect | |
| if: ${{!cancelled() && needs.collect.outputs.builderMatrixStage1 != ''}} | |
| uses: ./.github/workflows/container_builder.yml | |
| with: | |
| registry: ghcr.io | |
| username: nikleberg | |
| release: ${{github.ref_name == 'main'}} | |
| builderMatrix: ${{needs.collect.outputs.builderMatrixStage1}} | |
| secrets: | |
| password: ${{secrets.GITHUB_TOKEN}} | |
| stage2: | |
| name: Build Stage 2 Images | |
| needs: [collect, stage1] | |
| if: ${{!cancelled() && needs.collect.outputs.builderMatrixStage2 != ''}} | |
| uses: ./.github/workflows/container_builder.yml | |
| with: | |
| registry: ghcr.io | |
| username: nikleberg | |
| release: ${{github.ref_name == 'main'}} | |
| builderMatrix: ${{needs.collect.outputs.builderMatrixStage2}} | |
| secrets: | |
| password: ${{secrets.GITHUB_TOKEN}} | |
| stage3: | |
| name: Build Stage 3 Images | |
| needs: [collect, stage2] | |
| if: ${{!cancelled() && needs.collect.outputs.builderMatrixStage3 != ''}} | |
| uses: ./.github/workflows/container_builder.yml | |
| with: | |
| registry: ghcr.io | |
| username: nikleberg | |
| release: ${{github.ref_name == 'main'}} | |
| builderMatrix: ${{needs.collect.outputs.builderMatrixStage3}} | |
| secrets: | |
| password: ${{secrets.GITHUB_TOKEN}} | |
| summarize: | |
| # Allows to enforce branch protection rules by requiring that this job | |
| # and expecially all its 'needs' succeeded. | |
| # See: https://github.com/actions/runner/issues/491 | |
| name: Summarize | |
| runs-on: ubuntu-22.04 | |
| needs: [collect, stage1, stage2, stage3] | |
| if: ${{always()}} | |
| steps: | |
| - name: Successful builds? | |
| run: | | |
| if ${{ contains(needs.*.result, 'failure') }}; then | |
| echo "One or more matrix builds have failed!" | |
| false | |
| fi | |
| if ${{ contains(needs.*.result, 'cancelled') }}; then | |
| echo "One or more matrix builds were cancelled!" | |
| false | |
| fi | |
| shell: bash |