bug: add export of image-builder built artifact #26
Workflow file for this run
This file contains 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: Release Pull Request | |
on: | |
pull_request_target: | |
types: [ synchronize, opened, reopened, ready_for_review ] | |
branches: | |
- 'release-**' | |
jobs: | |
build-image: | |
name: Build manager image | |
if: github.event.pull_request.draft == false | |
runs-on: ubuntu-latest | |
steps: | |
- id: build | |
uses: kyma-project/test-infra/.github/workflows/image-builder.yml@main | |
with: | |
name: api-gateway-manager | |
dockerfile: Dockerfile | |
context: . | |
build-args: | | |
VERSION=PR-${{ github.event.number }} | |
- id: save | |
run: | | |
# taking only first image is enough, because 'images' point to single image with multiple tags | |
img="$(echo ${{ steps.build.outputs.images }} | jq -r '.[0]')" | |
dest="api-gateway-manager:PR-${{ github.event.number }}" | |
docker pull "$img" | |
docker tag "$img" "$dest" | |
docker save "$dest" > /tmp/manager-image.tar | |
- id: upload | |
uses: actions/upload-artifact@v4 | |
with: | |
path: /tmp/manager-image.tar | |
name: manager-image | |
unit-tests: | |
name: Unit tests & lint | |
if: github.event.pull_request.draft == false | |
uses: ./.github/workflows/pull-unit-lint.yaml | |
secrets: inherit | |
integration-tests: | |
name: Integration tests | |
needs: [ build-image ] | |
if: github.event.pull_request.draft == false | |
uses: ./.github/workflows/pull-integration-release.yaml | |
secrets: inherit | |
ui-tests: | |
name: UI tests | |
needs: [build-image] | |
if: github.event.pull_request.draft == false | |
uses: ./.github/workflows/ui-tests.yaml | |
secrets: inherit | |
verify-pins: | |
name: Verify-commit-pins | |
if: github.event.pull_request.draft == false | |
uses: ./.github/workflows/verify-commit-pins.yaml | |
secrets: inherit | |
pull-request-status: | |
needs: [ build-image, unit-tests, integration-tests, ui-tests, verify-pins ] | |
runs-on: ubuntu-latest | |
if: always() | |
steps: | |
- if: ${{ !(contains(needs.*.result, 'failure')) }} | |
run: exit 0 | |
- if: ${{ contains(needs.*.result, 'failure') }} | |
run: exit 1 |