CI / PR 209 #1452
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 | |
| run-name: ${{ inputs.qualification_request && format('CI / qualification / {0}', inputs.qualification_request) || format('CI / {0}', github.event_name == 'pull_request' && format('PR {0}', github.event.number) || github.ref_name) }} | |
| on: | |
| pull_request: | |
| types: [opened, synchronize, reopened, closed] | |
| merge_group: | |
| types: [checks_requested] | |
| push: | |
| branches: [main] | |
| workflow_dispatch: | |
| inputs: | |
| qualification_request: | |
| description: Exact source and product-scope request key supplied by release preparation | |
| required: false | |
| default: '' | |
| type: string | |
| release_products_json: | |
| description: Product IDs to qualify as a JSON array; empty array runs the exhaustive audit | |
| required: false | |
| default: '[]' | |
| type: string | |
| wasm_target: | |
| description: WASM AOT target to build when WASM runtime inputs are affected | |
| required: true | |
| default: all | |
| type: choice | |
| options: | |
| - all | |
| - macos-arm64 | |
| - linux-x64-gnu | |
| - linux-arm64-gnu | |
| - windows-x64-msvc | |
| native_target: | |
| description: Native target, or mobile compatibility domain, for focused manual debugging | |
| required: true | |
| default: all | |
| type: choice | |
| options: | |
| - all | |
| - macos-arm64 | |
| - linux-x64-gnu | |
| - linux-arm64-gnu | |
| - windows-x64-msvc | |
| - android-arm64-v8a | |
| - android-x86_64 | |
| - ios-xcframework | |
| mobile_target: | |
| description: Mobile lane to run for focused manual debugging | |
| required: true | |
| default: all | |
| type: choice | |
| options: | |
| - all | |
| - android | |
| - ios | |
| - both | |
| save_heavy_caches: | |
| description: Write the bounded heavy build caches when manually qualifying main | |
| required: true | |
| default: false | |
| type: boolean | |
| permissions: | |
| contents: read | |
| concurrency: | |
| group: ci-${{ github.event_name == 'pull_request' && format('pr-{0}', github.event.number) || format('sha-{0}', github.sha) }} | |
| cancel-in-progress: ${{ github.event_name == 'pull_request' }} | |
| env: | |
| CARGO_TERM_COLOR: always | |
| RUST_BACKTRACE: 1 | |
| NPM_VERSION: 11.18.0 | |
| DENO_VERSION: v2.8.1 | |
| ACTIONLINT_VERSION: 1.7.12 | |
| ASSET_PROFILE: release | |
| WASMER_LLVM_VERSION: "22.1" | |
| WASMER_LLVM_LINUX_X64_URL: https://github.com/wasmerio/llvm-custom-builds/releases/download/22.x/llvm-linux-amd64.tar.xz | |
| WASMER_LLVM_LINUX_X64_SHA256: 5fb1c687c5e895d517a23e7aabea9ec3557e3a3e33f8a8d3a8d21395157b3906 | |
| WASMER_LLVM_LINUX_X64_BYTES: 741670068 | |
| WASMER_LLVM_MACOS_ARM64_URL: https://github.com/wasmerio/llvm-custom-builds/releases/download/22.x/llvm-darwin-aarch64.tar.xz | |
| WASMER_LLVM_MACOS_ARM64_SHA256: f64460f6c8a28876737402542fc5b28bb1f4262cef85f799b65ce2a7ee6f8847 | |
| WASMER_LLVM_MACOS_ARM64_BYTES: 479103872 | |
| HEAVY_CACHE_SAVE_IF: ${{ (github.event_name == 'push' && github.ref == 'refs/heads/main') || (github.event_name == 'workflow_dispatch' && github.ref == 'refs/heads/main' && inputs.save_heavy_caches) }} | |
| MOON_BASE: ${{ github.event.pull_request.base.sha || github.event.before || github.event.merge_group.base_sha || '' }} | |
| MOON_HEAD: ${{ github.event.pull_request.head.sha || github.event.merge_group.head_sha || github.sha }} | |
| defaults: | |
| run: | |
| shell: bash | |
| jobs: | |
| affected: | |
| name: Planning / Affected Work | |
| needs: | |
| - release-intent | |
| if: ${{ github.event_name != 'pull_request' || github.event.action != 'closed' }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 10 | |
| outputs: | |
| published_dependencies: ${{ steps.plan.outputs.published_dependencies }} | |
| mobile_extension_package_native_targets_ios_csv: ${{ steps.plan.outputs.mobile_extension_package_native_targets_ios_csv }} | |
| mobile_extension_package_native_targets_android_csv: ${{ steps.plan.outputs.mobile_extension_package_native_targets_android_csv }} | |
| broker_runtime_matrix_other: ${{ steps.plan.outputs.broker_runtime_matrix_other }} | |
| broker_runtime_matrix_linux: ${{ steps.plan.outputs.broker_runtime_matrix_linux }} | |
| liboliphaunt_native_desktop_runtime_matrix_other: ${{ steps.plan.outputs.liboliphaunt_native_desktop_runtime_matrix_other }} | |
| liboliphaunt_native_desktop_runtime_matrix_linux: ${{ steps.plan.outputs.liboliphaunt_native_desktop_runtime_matrix_linux }} | |
| extension_artifacts_native_matrix_other: ${{ steps.plan.outputs.extension_artifacts_native_matrix_other }} | |
| extension_artifacts_native_matrix_ios: ${{ steps.plan.outputs.extension_artifacts_native_matrix_ios }} | |
| extension_artifacts_native_matrix_android: ${{ steps.plan.outputs.extension_artifacts_native_matrix_android }} | |
| extension_artifacts_native_matrix_linux: ${{ steps.plan.outputs.extension_artifacts_native_matrix_linux }} | |
| builder_jobs: ${{ steps.plan.outputs.builder_jobs }} | |
| check_count: ${{ steps.target-matrices.outputs.check_count }} | |
| check_job_count: ${{ steps.target-matrices.outputs.check_job_count }} | |
| check_jobs: ${{ steps.target-matrices.outputs.check_jobs }} | |
| check_matrix: ${{ steps.target-matrices.outputs.check_matrix }} | |
| policy_count: ${{ steps.target-matrices.outputs.policy_count }} | |
| policy_matrix: ${{ steps.target-matrices.outputs.policy_matrix }} | |
| policy_requires_swift: ${{ steps.target-matrices.outputs.policy_requires_swift }} | |
| policy_requires_android_sdk: ${{ steps.target-matrices.outputs.policy_requires_android_sdk }} | |
| policy_requires_rust: ${{ steps.target-matrices.outputs.policy_requires_rust }} | |
| policy_requires_maintainer_tools: ${{ steps.target-matrices.outputs.policy_requires_maintainer_tools }} | |
| policy_requires_workspace: ${{ steps.target-matrices.outputs.policy_requires_workspace }} | |
| policy_requires_wasmer_llvm: ${{ steps.target-matrices.outputs.policy_requires_wasmer_llvm }} | |
| jobs: ${{ steps.plan.outputs.jobs }} | |
| e2e_jobs: ${{ steps.plan.outputs.e2e_jobs }} | |
| job_targets: ${{ steps.plan.outputs.job_targets }} | |
| broker_runtime_matrix: ${{ steps.plan.outputs.broker_runtime_matrix }} | |
| extension_artifacts_native_matrix: ${{ steps.plan.outputs.extension_artifacts_native_matrix }} | |
| extension_artifacts_wasix_matrix: ${{ steps.plan.outputs.extension_artifacts_wasix_matrix }} | |
| extension_package_products: ${{ steps.plan.outputs.extension_package_products }} | |
| extension_package_products_csv: ${{ steps.plan.outputs.extension_package_products_csv }} | |
| extension_package_sql_names: ${{ steps.plan.outputs.extension_package_sql_names }} | |
| extension_package_sql_names_csv: ${{ steps.plan.outputs.extension_package_sql_names_csv }} | |
| native_extension_lifecycle_sql_names: ${{ steps.plan.outputs.native_extension_lifecycle_sql_names }} | |
| native_extension_lifecycle_sql_names_csv: ${{ steps.plan.outputs.native_extension_lifecycle_sql_names_csv }} | |
| native_extension_lifecycle_matrix: ${{ steps.plan.outputs.native_extension_lifecycle_matrix }} | |
| native_extension_lifecycle_shard_count: ${{ steps.plan.outputs.native_extension_lifecycle_shard_count }} | |
| liboliphaunt_wasix_aot_runtime_matrix: ${{ steps.plan.outputs.liboliphaunt_wasix_aot_runtime_matrix }} | |
| liboliphaunt_wasix_postmaster_runtime_matrix: ${{ steps.plan.outputs.liboliphaunt_wasix_postmaster_runtime_matrix }} | |
| liboliphaunt_native_android_runtime_matrix: ${{ steps.plan.outputs.liboliphaunt_native_android_runtime_matrix }} | |
| liboliphaunt_native_desktop_runtime_matrix: ${{ steps.plan.outputs.liboliphaunt_native_desktop_runtime_matrix }} | |
| liboliphaunt_native_ios_runtime_matrix: ${{ steps.plan.outputs.liboliphaunt_native_ios_runtime_matrix }} | |
| mobile_extension_package_native_targets: ${{ steps.plan.outputs.mobile_extension_package_native_targets }} | |
| mobile_extension_package_native_targets_csv: ${{ steps.plan.outputs.mobile_extension_package_native_targets_csv }} | |
| react_native_android_mobile_app_matrix: ${{ steps.plan.outputs.react_native_android_mobile_app_matrix }} | |
| node_direct_runtime_matrix: ${{ steps.plan.outputs.node_direct_runtime_matrix }} | |
| wasix_napi_runtime_matrix: ${{ steps.plan.outputs.wasix_napi_runtime_matrix }} | |
| projects: ${{ steps.plan.outputs.projects }} | |
| tasks: ${{ steps.plan.outputs.tasks }} | |
| test_count: ${{ steps.target-matrices.outputs.test_count }} | |
| test_jobs: ${{ steps.target-matrices.outputs.test_jobs }} | |
| test_matrix: ${{ steps.target-matrices.outputs.test_matrix }} | |
| reason: ${{ steps.plan.outputs.reason }} | |
| qualification_mode: ${{ steps.plan.outputs.qualification_mode }} | |
| qualification_base_sha: ${{ steps.plan.outputs.qualification_base_sha }} | |
| qualification_head_sha: ${{ steps.plan.outputs.qualification_head_sha }} | |
| wasix_release_regression_required: ${{ contains(fromJson(steps.plan.outputs.jobs), 'liboliphaunt-wasix-runtime') && (github.event_name != 'workflow_dispatch' || inputs.wasm_target == 'all' || inputs.wasm_target == 'linux-x64-gnu') }} | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| with: | |
| install-workspace: "false" | |
| - name: Plan artifact builder jobs | |
| id: plan | |
| env: | |
| GITHUB_EVENT_NAME: ${{ github.event_name }} | |
| MOON_BASE: ${{ github.event.pull_request.base.sha || github.event.before || github.event.merge_group.base_sha }} | |
| MOON_HEAD: ${{ github.event.pull_request.head.sha || github.event.merge_group.head_sha || github.sha }} | |
| WASM_TARGET: ${{ github.event_name == 'workflow_dispatch' && inputs.wasm_target || 'all' }} | |
| NATIVE_TARGET: ${{ github.event_name == 'workflow_dispatch' && inputs.native_target || 'all' }} | |
| MOBILE_TARGET: ${{ github.event_name == 'workflow_dispatch' && inputs.mobile_target || 'all' }} | |
| CI_RELEASE_PRODUCTS_JSON: ${{ inputs.release_products_json || '[]' }} | |
| CI_QUALIFICATION_REQUEST: ${{ inputs.qualification_request || '' }} | |
| CI_GENERATED_RELEASE_PR: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.ref == 'release-please--branches--main' && github.event.pull_request.head.repo.full_name == github.repository }} | |
| run: bash tools/ci/ci-plan.sh | |
| - name: Plan check and test jobs | |
| id: target-matrices | |
| env: | |
| CI_PLAN_PATH: target/graph/ci-plan.json | |
| CI_QUALIFICATION_MODE: ${{ steps.plan.outputs.qualification_mode }} | |
| MOON_BASE: ${{ github.event.pull_request.base.sha || github.event.before || github.event.merge_group.base_sha }} | |
| MOON_HEAD: ${{ github.event.pull_request.head.sha || github.event.merge_group.head_sha || github.sha }} | |
| run: bash .github/scripts/write-affected-moon-target-matrices.sh | |
| - name: Upload build plan | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: artifact-build-plan | |
| path: target/graph/ci-plan.json | |
| if-no-files-found: error | |
| release-intent: | |
| name: Planning / Release Intent | |
| if: ${{ github.event_name != 'pull_request' || github.event.action != 'closed' }} | |
| permissions: | |
| actions: read | |
| contents: read | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 10 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| with: | |
| install-workspace: "false" | |
| - name: Check release intent | |
| env: | |
| PR_TITLE: ${{ github.event.pull_request.title }} | |
| BASE_REF: ${{ github.event.pull_request.base.sha || github.event.before || github.event.merge_group.base_sha || (github.event_name == 'workflow_dispatch' && github.ref == 'refs/heads/main' && format('{0}^', github.sha)) || 'origin/main' }} | |
| HEAD_REF: ${{ github.event.pull_request.head.sha || github.event.merge_group.head_sha || github.sha }} | |
| HEAD_BRANCH: ${{ github.event.pull_request.head.ref || github.ref_name }} | |
| CI_EVENT_NAME: ${{ github.event_name }} | |
| CI_FULL_REF: ${{ github.ref }} | |
| run: | | |
| subject="${PR_TITLE:-}" | |
| if [ -z "$subject" ]; then | |
| subject="$(git log -1 --pretty=%s "$HEAD_REF")" | |
| fi | |
| .github/scripts/check-release-intent.sh "$subject" "$BASE_REF" "$HEAD_REF" "$HEAD_BRANCH" "$CI_EVENT_NAME" "$CI_FULL_REF" | |
| - name: Require normalized generated release | |
| id: generated_release_readiness | |
| if: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.ref == 'release-please--branches--main' && github.event.pull_request.head.repo.full_name == github.repository }} | |
| run: bash tools/release/sync-release-pr.sh --check-generated-release | |
| check-targets: | |
| name: Checks / ${{ matrix.label }} | |
| needs: | |
| - affected | |
| if: ${{ needs.affected.outputs.check_count != '0' }} | |
| strategy: | |
| fail-fast: false | |
| matrix: ${{ fromJson(needs.affected.outputs.check_matrix) }} | |
| runs-on: ${{ matrix.runner }} | |
| timeout-minutes: 90 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| with: | |
| install-workspace: ${{ matrix.requires_workspace && 'true' || 'false' }} | |
| - name: Set up Rust | |
| if: ${{ matrix.requires_rust }} | |
| uses: ./.github/actions/setup-rust | |
| - name: Install Android Rust targets | |
| if: ${{ matrix.requires_rust && matrix.requires_android_sdk }} | |
| run: rustup target add aarch64-linux-android x86_64-linux-android | |
| - name: Set up Swift | |
| if: ${{ matrix.requires_swift && !matrix.requires_apple }} | |
| uses: ./.github/actions/setup-swift | |
| - name: Set up Apple | |
| if: ${{ matrix.requires_apple }} | |
| uses: ./.github/actions/setup-apple | |
| with: | |
| install-build-dependencies: "false" | |
| - name: Set up Android | |
| if: ${{ matrix.requires_android_sdk }} | |
| uses: ./.github/actions/setup-android | |
| - name: Set up Wasmer LLVM | |
| if: ${{ matrix.requires_wasmer_llvm }} | |
| uses: ./.github/actions/setup-wasmer-llvm | |
| with: | |
| url: ${{ runner.os == 'macOS' && env.WASMER_LLVM_MACOS_ARM64_URL || env.WASMER_LLVM_LINUX_X64_URL }} | |
| sha256: ${{ runner.os == 'macOS' && env.WASMER_LLVM_MACOS_ARM64_SHA256 || env.WASMER_LLVM_LINUX_X64_SHA256 }} | |
| bytes: ${{ runner.os == 'macOS' && env.WASMER_LLVM_MACOS_ARM64_BYTES || env.WASMER_LLVM_LINUX_X64_BYTES }} | |
| version: ${{ env.WASMER_LLVM_VERSION }} | |
| - name: Install pinned maintainer tools | |
| if: ${{ matrix.requires_maintainer_tools }} | |
| run: tools/dev/bootstrap-tools.sh --workflows | |
| - name: Run checks | |
| env: | |
| MOON_TARGET_MATRIX_JSON: ${{ matrix.targets_json }} | |
| run: bash .github/scripts/run-moon-targets.sh --matrix | |
| policy-targets: | |
| name: Checks / Policy | |
| needs: | |
| - affected | |
| if: ${{ needs.affected.outputs.policy_count != '0' }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 90 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| with: | |
| install-workspace: ${{ needs.affected.outputs.policy_requires_workspace == 'true' && 'true' || 'false' }} | |
| - name: Set up Rust | |
| if: ${{ needs.affected.outputs.policy_requires_rust == 'true' }} | |
| uses: ./.github/actions/setup-rust | |
| - name: Set up Swift | |
| if: ${{ needs.affected.outputs.policy_requires_swift == 'true' }} | |
| uses: ./.github/actions/setup-swift | |
| - name: Set up Android | |
| if: ${{ needs.affected.outputs.policy_requires_android_sdk == 'true' }} | |
| uses: ./.github/actions/setup-android | |
| - name: Set up Wasmer LLVM | |
| if: ${{ needs.affected.outputs.policy_requires_wasmer_llvm == 'true' }} | |
| uses: ./.github/actions/setup-wasmer-llvm | |
| with: | |
| url: ${{ env.WASMER_LLVM_LINUX_X64_URL }} | |
| sha256: ${{ env.WASMER_LLVM_LINUX_X64_SHA256 }} | |
| bytes: ${{ env.WASMER_LLVM_LINUX_X64_BYTES }} | |
| version: ${{ env.WASMER_LLVM_VERSION }} | |
| - name: Install pinned maintainer tools | |
| if: ${{ needs.affected.outputs.policy_requires_maintainer_tools == 'true' }} | |
| run: tools/dev/bootstrap-tools.sh --workflows | |
| - name: Run selected policy targets | |
| env: | |
| MOON_TARGET_MATRIX_JSON: ${{ needs.affected.outputs.policy_matrix }} | |
| run: bash .github/scripts/run-moon-targets.sh --matrix | |
| checks: | |
| name: Checks | |
| if: ${{ !cancelled() && (github.event_name != 'pull_request' || github.event.action != 'closed') }} | |
| needs: | |
| - affected | |
| - check-targets | |
| - policy-targets | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 5 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 1 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Bun | |
| uses: ./.github/actions/setup-bun | |
| - name: Check selected check and policy jobs | |
| id: selected_checks_gate | |
| env: | |
| NEEDS_JSON: ${{ toJson(needs) }} | |
| SELECTED_JOBS_JSON: ${{ needs.affected.outputs.check_jobs }} | |
| GATE_LABEL: selected check and policy jobs | |
| run: bun .github/scripts/check-ci-gate.mts selected | |
| test-targets: | |
| name: Tests / ${{ matrix.label }} | |
| needs: | |
| - affected | |
| if: ${{ needs.affected.outputs.test_count != '0' }} | |
| strategy: | |
| fail-fast: false | |
| matrix: ${{ fromJson(needs.affected.outputs.test_matrix) }} | |
| runs-on: ${{ matrix.runner }} | |
| timeout-minutes: 90 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| with: | |
| install-workspace: ${{ matrix.requires_workspace && 'true' || 'false' }} | |
| - name: Set up Rust | |
| if: ${{ matrix.requires_rust }} | |
| uses: ./.github/actions/setup-rust | |
| with: | |
| tools: cargo-nextest@0.9.137 | |
| - name: Set up Swift | |
| if: ${{ matrix.requires_swift && !matrix.requires_apple }} | |
| uses: ./.github/actions/setup-swift | |
| - name: Set up Apple | |
| if: ${{ matrix.requires_apple }} | |
| uses: ./.github/actions/setup-apple | |
| with: | |
| install-build-dependencies: "false" | |
| - name: Set up Android | |
| if: ${{ matrix.requires_android_sdk }} | |
| uses: ./.github/actions/setup-android | |
| - name: Set up Wasmer LLVM | |
| if: ${{ matrix.requires_wasmer_llvm }} | |
| uses: ./.github/actions/setup-wasmer-llvm | |
| with: | |
| url: ${{ runner.os == 'macOS' && env.WASMER_LLVM_MACOS_ARM64_URL || env.WASMER_LLVM_LINUX_X64_URL }} | |
| sha256: ${{ runner.os == 'macOS' && env.WASMER_LLVM_MACOS_ARM64_SHA256 || env.WASMER_LLVM_LINUX_X64_SHA256 }} | |
| bytes: ${{ runner.os == 'macOS' && env.WASMER_LLVM_MACOS_ARM64_BYTES || env.WASMER_LLVM_LINUX_X64_BYTES }} | |
| version: ${{ env.WASMER_LLVM_VERSION }} | |
| - name: Install pinned maintainer tools | |
| if: ${{ matrix.requires_maintainer_tools }} | |
| run: tools/dev/bootstrap-tools.sh --workflows | |
| - name: Run tests | |
| env: | |
| MOON_TARGET_MATRIX_JSON: ${{ matrix.targets_json }} | |
| run: bash .github/scripts/run-moon-targets.sh --matrix | |
| tests: | |
| name: Tests | |
| if: ${{ !cancelled() && (github.event_name != 'pull_request' || github.event.action != 'closed') }} | |
| needs: | |
| - affected | |
| - test-targets | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 5 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 1 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Bun | |
| uses: ./.github/actions/setup-bun | |
| - name: Check selected test jobs | |
| id: selected_tests_gate | |
| env: | |
| NEEDS_JSON: ${{ toJson(needs) }} | |
| SELECTED_JOBS_JSON: ${{ needs.affected.outputs.test_jobs }} | |
| GATE_LABEL: selected test jobs | |
| run: bun .github/scripts/check-ci-gate.mts selected | |
| extension-artifacts-native-linux: | |
| needs: [affected, checks, tests] | |
| if: ${{ fromJson(needs.affected.outputs.extension_artifacts_native_matrix_linux).include[0] != null }} | |
| uses: ./.github/workflows/extension-artifacts-native.yml | |
| with: | |
| matrix: ${{ needs.affected.outputs.extension_artifacts_native_matrix_linux }} | |
| job-targets: ${{ needs.affected.outputs.job_targets }} | |
| extension-artifacts-native-android: | |
| needs: [affected, checks, tests] | |
| if: ${{ fromJson(needs.affected.outputs.extension_artifacts_native_matrix_android).include[0] != null }} | |
| uses: ./.github/workflows/extension-artifacts-native.yml | |
| with: | |
| matrix: ${{ needs.affected.outputs.extension_artifacts_native_matrix_android }} | |
| job-targets: ${{ needs.affected.outputs.job_targets }} | |
| extension-artifacts-native-ios: | |
| needs: [affected, checks, tests] | |
| if: ${{ fromJson(needs.affected.outputs.extension_artifacts_native_matrix_ios).include[0] != null }} | |
| uses: ./.github/workflows/extension-artifacts-native.yml | |
| with: | |
| matrix: ${{ needs.affected.outputs.extension_artifacts_native_matrix_ios }} | |
| job-targets: ${{ needs.affected.outputs.job_targets }} | |
| extension-artifacts-native-other: | |
| needs: [affected, checks, tests] | |
| if: ${{ fromJson(needs.affected.outputs.extension_artifacts_native_matrix_other).include[0] != null }} | |
| uses: ./.github/workflows/extension-artifacts-native.yml | |
| with: | |
| matrix: ${{ needs.affected.outputs.extension_artifacts_native_matrix_other }} | |
| job-targets: ${{ needs.affected.outputs.job_targets }} | |
| extension-artifacts-native: | |
| name: Builds / extension-artifacts-native | |
| needs: [affected, extension-artifacts-native-linux, extension-artifacts-native-android, extension-artifacts-native-ios, extension-artifacts-native-other] | |
| if: ${{ !cancelled() && !failure() && contains(fromJson(needs.affected.outputs.jobs), 'extension-artifacts-native') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 5 | |
| steps: | |
| - name: Check selected platform producers | |
| env: | |
| RESULTS: ${{ join(needs.*.result, ',') }} | |
| run: | | |
| case ",$RESULTS," in | |
| *,failure,*|*,cancelled,*) exit 1 ;; | |
| esac | |
| extension-artifacts-wasix: | |
| name: Builds / WASIX Extension Artifacts (${{ matrix.target }}) | |
| needs: | |
| - affected | |
| - liboliphaunt-wasix-runtime | |
| if: ${{ contains(fromJson(needs.affected.outputs.jobs), 'extension-artifacts-wasix') }} | |
| strategy: | |
| fail-fast: false | |
| matrix: ${{ fromJson(needs.affected.outputs.extension_artifacts_wasix_matrix) }} | |
| runs-on: ${{ matrix.runner }} | |
| timeout-minutes: 120 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| - name: Set up Rust | |
| uses: ./.github/actions/setup-rust | |
| - name: Download portable WASIX runtime outputs | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-wasix-runtime-portable | |
| path: . | |
| - name: Download WASIX extension compiler outputs | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: extensions-wasix-compiler-output | |
| path: target/extensions/wasix/assets | |
| - name: Build WASIX exact-extension artifacts | |
| env: | |
| OLIPHAUNT_EXTENSION_PRODUCTS: ${{ matrix.extensions_csv }} | |
| OLIPHAUNT_EXTENSION_TARGET: ${{ matrix.target }} | |
| OLIPHAUNT_MOON_TRANSFERRED_DEPS_JSON: '["extension-artifacts-wasix:compiler-output"]' | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-planned-moon-job.sh extension-artifacts-wasix | |
| - name: Upload WASIX exact-extension artifacts | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: liboliphaunt-wasix-extension-artifacts-${{ matrix.target }} | |
| path: target/extensions/wasix/release-assets | |
| if-no-files-found: error | |
| extension-packages: | |
| name: Builds / Extension Packages | |
| needs: | |
| - affected | |
| - extension-artifacts-native | |
| - extension-artifacts-wasix | |
| - liboliphaunt-wasix-aot | |
| if: ${{ !cancelled() && !failure() && needs.affected.result == 'success' && needs.extension-artifacts-native.result == 'success' && needs.extension-artifacts-wasix.result == 'success' && needs.liboliphaunt-wasix-aot.result == 'success' && contains(fromJson(needs.affected.outputs.jobs), 'extension-packages') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 30 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| - name: Set up Rust | |
| uses: ./.github/actions/setup-rust | |
| - name: Download native exact-extension artifacts | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| pattern: liboliphaunt-native-extension-artifacts-* | |
| path: target/extensions/native/release-assets | |
| merge-multiple: true | |
| - name: Download WASIX exact-extension artifacts | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| pattern: liboliphaunt-wasix-extension-artifacts-* | |
| path: target/extensions/wasix/release-assets | |
| merge-multiple: true | |
| - name: Download WASIX exact-extension AOT artifacts | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| pattern: liboliphaunt-wasix-extension-aot-* | |
| path: target/extensions/wasix/aot-artifacts | |
| merge-multiple: true | |
| - name: Assemble exact-extension product packages | |
| env: | |
| OLIPHAUNT_EXTENSION_PACKAGE_PRODUCTS: ${{ needs.affected.outputs.extension_package_products_csv }} | |
| OLIPHAUNT_MOON_TRANSFERRED_DEPS_JSON: '["extension-artifacts-native:build-target", "extension-artifacts-wasix:build-target", "extension-artifacts-wasix:build-aot"]' | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-planned-moon-job.sh extension-packages | |
| - name: Upload exact-extension package artifacts | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: oliphaunt-extension-package-artifacts | |
| path: target/extension-artifacts | |
| if-no-files-found: error | |
| mobile-extension-packages-android: | |
| needs: [affected, extension-artifacts-native-android] | |
| if: ${{ needs.affected.outputs.mobile_extension_package_native_targets_android_csv != '' }} | |
| uses: ./.github/workflows/mobile-extension-packages.yml | |
| with: | |
| family: android | |
| targets: ${{ needs.affected.outputs.mobile_extension_package_native_targets_android_csv }} | |
| products: ${{ needs.affected.outputs.extension_package_products_csv }} | |
| job-targets: ${{ needs.affected.outputs.job_targets }} | |
| mobile-extension-packages-ios: | |
| needs: [affected, extension-artifacts-native-ios] | |
| if: ${{ needs.affected.outputs.mobile_extension_package_native_targets_ios_csv != '' }} | |
| uses: ./.github/workflows/mobile-extension-packages.yml | |
| with: | |
| family: ios | |
| targets: ${{ needs.affected.outputs.mobile_extension_package_native_targets_ios_csv }} | |
| products: ${{ needs.affected.outputs.extension_package_products_csv }} | |
| job-targets: ${{ needs.affected.outputs.job_targets }} | |
| mobile-extension-packages: | |
| needs: [affected, mobile-extension-packages-android, mobile-extension-packages-ios] | |
| if: ${{ !cancelled() && !failure() && contains(fromJson(needs.affected.outputs.jobs), 'mobile-extension-packages') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 5 | |
| steps: | |
| - name: Check selected mobile producers | |
| env: | |
| RESULTS: ${{ join(needs.*.result, ',') }} | |
| run: | | |
| case ",$RESULTS," in | |
| *,failure,*|*,cancelled,*) exit 1 ;; | |
| esac | |
| liboliphaunt-native-desktop-linux: | |
| needs: [affected, checks, tests] | |
| if: ${{ fromJson(needs.affected.outputs.liboliphaunt_native_desktop_runtime_matrix_linux).include[0] != null }} | |
| uses: ./.github/workflows/liboliphaunt-native-desktop.yml | |
| with: | |
| matrix: ${{ needs.affected.outputs.liboliphaunt_native_desktop_runtime_matrix_linux }} | |
| job-targets: ${{ needs.affected.outputs.job_targets }} | |
| liboliphaunt-native-desktop-other: | |
| needs: [affected, checks, tests] | |
| if: ${{ fromJson(needs.affected.outputs.liboliphaunt_native_desktop_runtime_matrix_other).include[0] != null }} | |
| uses: ./.github/workflows/liboliphaunt-native-desktop.yml | |
| with: | |
| matrix: ${{ needs.affected.outputs.liboliphaunt_native_desktop_runtime_matrix_other }} | |
| job-targets: ${{ needs.affected.outputs.job_targets }} | |
| liboliphaunt-native-desktop: | |
| name: Builds / liboliphaunt-native-desktop | |
| needs: [affected, liboliphaunt-native-desktop-linux, liboliphaunt-native-desktop-other] | |
| if: ${{ !cancelled() && !failure() && contains(fromJson(needs.affected.outputs.jobs), 'liboliphaunt-native-desktop') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 5 | |
| steps: | |
| - name: Check selected platform producers | |
| env: | |
| RESULTS: ${{ join(needs.*.result, ',') }} | |
| run: | | |
| case ",$RESULTS," in | |
| *,failure,*|*,cancelled,*) exit 1 ;; | |
| esac | |
| liboliphaunt-native-android: | |
| name: Builds / Native Runtime (${{ matrix.target }}) | |
| needs: | |
| - affected | |
| - checks | |
| - tests | |
| if: ${{ contains(fromJson(needs.affected.outputs.jobs), 'liboliphaunt-native-android') }} | |
| strategy: | |
| fail-fast: false | |
| matrix: ${{ fromJson(needs.affected.outputs.liboliphaunt_native_android_runtime_matrix) }} | |
| runs-on: ${{ matrix.runner }} | |
| timeout-minutes: 120 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| - name: Set up Rust | |
| uses: ./.github/actions/setup-rust | |
| - name: Set up Android | |
| uses: ./.github/actions/setup-android | |
| with: | |
| gradle-cache: "false" | |
| native-ccache: "true" | |
| - name: Prepare native build path | |
| env: | |
| NATIVE_BUILD_ROOT: ${{ matrix.build-root }} | |
| run: mkdir -p "$NATIVE_BUILD_ROOT" | |
| - name: Configure native compiler cache | |
| run: .github/scripts/setup-native-build-tools.sh 2G | |
| - name: Build and package liboliphaunt Android target | |
| env: | |
| OLIPHAUNT_CI_JOB_TARGETS_JSON: ${{ needs.affected.outputs.job_targets }} | |
| OLIPHAUNT_NATIVE_TASK: ${{ contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-native-android'], format('liboliphaunt-native:package-runtime-{0}', matrix.target)) && format('liboliphaunt-native:package-runtime-{0}', matrix.target) || format('liboliphaunt-native:build-runtime-{0}', matrix.target) }} | |
| run: .github/scripts/run-planned-moon-job.sh liboliphaunt-native-android "$OLIPHAUNT_NATIVE_TASK" | |
| - name: Upload liboliphaunt release assets | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-native-android'], format('liboliphaunt-native:package-runtime-{0}', matrix.target)) }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: liboliphaunt-native-release-assets-${{ matrix.target }} | |
| path: target/liboliphaunt/mobile-release-assets/${{ matrix.target }} | |
| if-no-files-found: error | |
| - name: Preserve native build file modes and symlinks | |
| env: | |
| NATIVE_ARTIFACT_ROOT: ${{ matrix.ci-artifact-root }} | |
| run: tar -czf "$RUNNER_TEMP/native-target.tar.gz" -C "$NATIVE_ARTIFACT_ROOT" . | |
| - name: Upload liboliphaunt Android target artifacts | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: liboliphaunt-native-target-${{ matrix.target }} | |
| path: ${{ runner.temp }}/native-target.tar.gz | |
| if-no-files-found: error | |
| - name: Show native compiler cache stats | |
| if: ${{ always() }} | |
| run: | | |
| if command -v ccache >/dev/null 2>&1; then | |
| ccache --show-stats | |
| fi | |
| - name: Upload liboliphaunt Android build logs | |
| if: ${{ failure() }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: liboliphaunt-logs-${{ matrix.target }} | |
| path: | | |
| ${{ matrix.build-root }}/*.log | |
| target/liboliphaunt/**/*.log | |
| if-no-files-found: ignore | |
| liboliphaunt-native-ios: | |
| name: Builds / Native Runtime (${{ matrix.target }}) | |
| needs: | |
| - affected | |
| - checks | |
| - tests | |
| if: ${{ contains(fromJson(needs.affected.outputs.jobs), 'liboliphaunt-native-ios') }} | |
| strategy: | |
| fail-fast: false | |
| matrix: ${{ fromJson(needs.affected.outputs.liboliphaunt_native_ios_runtime_matrix) }} | |
| runs-on: ${{ matrix.runner }} | |
| timeout-minutes: 120 | |
| env: | |
| CCACHE_DIR: ${{ github.workspace }}/.ci-cache/ccache/native-runtime/${{ matrix.target }} | |
| CCACHE_BASEDIR: ${{ github.workspace }} | |
| CCACHE_COMPILERCHECK: content | |
| CCACHE_COMPRESS: "true" | |
| OLIPHAUNT_CCACHE_ZERO_STATS: "1" | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| - name: Set up Apple | |
| uses: ./.github/actions/setup-apple | |
| - name: Set up Rust | |
| uses: ./.github/actions/setup-rust | |
| - name: Prepare native build paths | |
| env: | |
| NATIVE_BUILD_ROOT: ${{ matrix.build-root }} | |
| run: mkdir -p "$CCACHE_DIR" "$NATIVE_BUILD_ROOT" | |
| - name: Configure native compiler cache | |
| run: .github/scripts/setup-native-build-tools.sh 2G | |
| - name: Build and package liboliphaunt iOS target | |
| env: | |
| OLIPHAUNT_CI_JOB_TARGETS_JSON: ${{ needs.affected.outputs.job_targets }} | |
| OLIPHAUNT_NATIVE_TASK: ${{ contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-native-ios'], format('liboliphaunt-native:package-runtime-{0}', matrix.target)) && format('liboliphaunt-native:package-runtime-{0}', matrix.target) || format('liboliphaunt-native:build-runtime-{0}', matrix.target) }} | |
| run: .github/scripts/run-planned-moon-job.sh liboliphaunt-native-ios "$OLIPHAUNT_NATIVE_TASK" | |
| - name: Upload liboliphaunt release assets | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-native-ios'], format('liboliphaunt-native:package-runtime-{0}', matrix.target)) }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: liboliphaunt-native-release-assets-${{ matrix.target }} | |
| path: target/liboliphaunt/mobile-release-assets/${{ matrix.target }} | |
| if-no-files-found: error | |
| - name: Preserve native build file modes and symlinks | |
| env: | |
| NATIVE_ARTIFACT_ROOT: ${{ matrix.ci-artifact-root }} | |
| run: tar -czf "$RUNNER_TEMP/native-target.tar.gz" -C "$NATIVE_ARTIFACT_ROOT" . | |
| - name: Upload liboliphaunt iOS target artifacts | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: liboliphaunt-native-target-${{ matrix.target }} | |
| path: ${{ runner.temp }}/native-target.tar.gz | |
| if-no-files-found: error | |
| - name: Show native compiler cache stats | |
| if: ${{ always() }} | |
| run: | | |
| if command -v ccache >/dev/null 2>&1; then | |
| ccache --show-stats | |
| fi | |
| - name: Upload liboliphaunt iOS build logs | |
| if: ${{ failure() }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: liboliphaunt-logs-${{ matrix.target }} | |
| path: | | |
| ${{ matrix.build-root }}/*.log | |
| ${{ matrix.build-root }}/logs/*.log | |
| ${{ matrix.build-root }}/**/*.log | |
| target/liboliphaunt-ios-simulator/*.log | |
| target/liboliphaunt-ios-simulator/**/*.log | |
| target/liboliphaunt-ios-device/*.log | |
| target/liboliphaunt-ios-device/**/*.log | |
| target/liboliphaunt/**/*.log | |
| if-no-files-found: ignore | |
| liboliphaunt-native-android-abi: | |
| name: Builds / Native Runtime ABI Compatibility (Android) | |
| needs: | |
| - affected | |
| - liboliphaunt-native-android | |
| if: ${{ !cancelled() && !failure() && needs.affected.result == 'success' && needs.liboliphaunt-native-android.result == 'success' && contains(fromJson(needs.affected.outputs.jobs), 'liboliphaunt-native-android-abi') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 30 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| - name: Download Android arm64 ABI receipts | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-native-target-android-arm64-v8a | |
| path: target/liboliphaunt-native-ci/android-arm64-v8a | |
| - name: Restore android-arm64-v8a build outputs | |
| run: | | |
| tar -xzf target/liboliphaunt-native-ci/android-arm64-v8a/native-target.tar.gz -C target/liboliphaunt-native-ci/android-arm64-v8a | |
| rm target/liboliphaunt-native-ci/android-arm64-v8a/native-target.tar.gz | |
| rsync -a target/liboliphaunt-native-ci/android-arm64-v8a/target/ target/ | |
| - name: Download Android x86_64 ABI receipts | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-native-target-android-x86_64 | |
| path: target/liboliphaunt-native-ci/android-x86_64 | |
| - name: Restore android-x86_64 build outputs | |
| run: | | |
| tar -xzf target/liboliphaunt-native-ci/android-x86_64/native-target.tar.gz -C target/liboliphaunt-native-ci/android-x86_64 | |
| rm target/liboliphaunt-native-ci/android-x86_64/native-target.tar.gz | |
| rsync -a target/liboliphaunt-native-ci/android-x86_64/target/ target/ | |
| - name: Download Android runtime-resource assets | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-native-android-abi'], 'liboliphaunt-native:finalize-runtime-android-abi') }} | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-native-release-assets-android-x86_64 | |
| path: target/liboliphaunt/mobile-release-assets/android-x86_64 | |
| - name: Prove Android Datum64 ABI-compatible runtime-resource closure | |
| env: | |
| OLIPHAUNT_CI_JOB_TARGETS_JSON: ${{ needs.affected.outputs.job_targets }} | |
| OLIPHAUNT_MOON_TRANSFERRED_DEPS_JSON: '["liboliphaunt-native:package-runtime-android-arm64-v8a","liboliphaunt-native:build-runtime-android-arm64-v8a","liboliphaunt-native:package-runtime-android-x86_64","liboliphaunt-native:build-runtime-android-x86_64"]' | |
| run: .github/scripts/run-planned-moon-job.sh liboliphaunt-native-android-abi | |
| - name: Upload ABI-compatible Android runtime-resource assets | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-native-android-abi'], 'liboliphaunt-native:finalize-runtime-android-abi') }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: liboliphaunt-native-abi-compatible-release-assets-android-datum64 | |
| path: target/liboliphaunt/abi-compatible-release-assets/android-datum64 | |
| if-no-files-found: error | |
| - name: Upload android database seeds | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-native-android-abi'], 'database-resources:build-native-android-standard') || contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-native-android-abi'], 'database-resources:build-native-android-icu') }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: database-resources-native-seeds-android-datum64 | |
| path: target/database-resources/release-assets/*seed-native-android-datum64-* | |
| if-no-files-found: error | |
| liboliphaunt-native-ios-abi: | |
| name: Builds / Native Runtime ABI Compatibility (iOS) | |
| needs: | |
| - affected | |
| - liboliphaunt-native-ios | |
| if: ${{ !cancelled() && !failure() && needs.affected.result == 'success' && needs.liboliphaunt-native-ios.result == 'success' && contains(fromJson(needs.affected.outputs.jobs), 'liboliphaunt-native-ios-abi') }} | |
| runs-on: ${{ (contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-native-ios-abi'], 'database-resources:build-native-ios-standard') || contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-native-ios-abi'], 'database-resources:build-native-ios-icu')) && 'macos-26' || 'ubuntu-24.04' }} | |
| timeout-minutes: 30 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| - name: Download iOS ABI receipts | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-native-target-ios-xcframework | |
| path: target/liboliphaunt-native-ci/ios-xcframework | |
| - name: Restore ios-xcframework build outputs | |
| run: | | |
| tar -xzf target/liboliphaunt-native-ci/ios-xcframework/native-target.tar.gz -C target/liboliphaunt-native-ci/ios-xcframework | |
| rm target/liboliphaunt-native-ci/ios-xcframework/native-target.tar.gz | |
| rsync -a target/liboliphaunt-native-ci/ios-xcframework/target/ target/ | |
| - name: Download iOS runtime-resource assets | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-native-ios-abi'], 'liboliphaunt-native:finalize-runtime-ios-abi') }} | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-native-release-assets-ios-xcframework | |
| path: target/liboliphaunt/mobile-release-assets/ios-xcframework | |
| - name: Prove iOS Datum64 ABI-compatible runtime-resource closure | |
| env: | |
| OLIPHAUNT_CI_JOB_TARGETS_JSON: ${{ needs.affected.outputs.job_targets }} | |
| OLIPHAUNT_MOON_TRANSFERRED_DEPS_JSON: '["liboliphaunt-native:package-runtime-ios-xcframework","liboliphaunt-native:build-runtime-ios-xcframework"]' | |
| run: .github/scripts/run-planned-moon-job.sh liboliphaunt-native-ios-abi | |
| - name: Upload ABI-compatible iOS runtime-resource assets | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-native-ios-abi'], 'liboliphaunt-native:finalize-runtime-ios-abi') }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: liboliphaunt-native-abi-compatible-release-assets-ios-datum64 | |
| path: target/liboliphaunt/abi-compatible-release-assets/ios-datum64 | |
| if-no-files-found: error | |
| - name: Upload ios database seeds | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-native-ios-abi'], 'database-resources:build-native-ios-standard') || contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-native-ios-abi'], 'database-resources:build-native-ios-icu') }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: database-resources-native-seeds-ios-datum64 | |
| path: target/database-resources/release-assets/*seed-native-ios-datum64-* | |
| if-no-files-found: error | |
| liboliphaunt-native-release-assets: | |
| name: Builds / Native Runtime Release Assets | |
| needs: | |
| - affected | |
| - liboliphaunt-native-android | |
| - liboliphaunt-native-android-abi | |
| - liboliphaunt-native-desktop | |
| - liboliphaunt-native-ios | |
| - liboliphaunt-native-ios-abi | |
| if: ${{ contains(fromJson(needs.affected.outputs.jobs), 'liboliphaunt-native-release-assets') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 30 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| - name: Set up Rust | |
| uses: ./.github/actions/setup-rust | |
| - name: Download liboliphaunt target release assets | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| pattern: liboliphaunt-native-release-assets-* | |
| path: target/liboliphaunt/release-assets | |
| merge-multiple: true | |
| - name: Remove raw mobile runtime-resource closures | |
| run: | | |
| set -- | |
| while IFS= read -r archive; do | |
| [ -n "$archive" ] && set -- "$@" "$archive" | |
| done < <(find target/liboliphaunt/release-assets -maxdepth 1 -type f \ | |
| \( -name 'liboliphaunt-*-runtime-resources-android-datum64.tar.gz' \ | |
| -o -name 'liboliphaunt-*-runtime-resources-ios-datum64.tar.gz' \) \ | |
| | LC_ALL=C sort) | |
| if [ "$#" -ne 2 ]; then | |
| echo "Expected exactly two raw mobile runtime-resource closures; found $#" >&2 | |
| exit 1 | |
| fi | |
| rm -- "$@" | |
| - name: Download ABI-compatible Android runtime-resource assets | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-native-abi-compatible-release-assets-android-datum64 | |
| path: target/liboliphaunt/release-assets | |
| - name: Download ABI-compatible iOS runtime-resource assets | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-native-abi-compatible-release-assets-ios-datum64 | |
| path: target/liboliphaunt/release-assets | |
| - name: Package aggregate liboliphaunt release assets | |
| env: | |
| OLIPHAUNT_MOON_TRANSFERRED_DEPS_JSON: '["liboliphaunt-native:package-runtime-desktop-target", "liboliphaunt-native:package-runtime-android-arm64-v8a", "liboliphaunt-native:package-runtime-android-x86_64", "liboliphaunt-native:package-runtime-ios-xcframework", "liboliphaunt-native:finalize-runtime-android-abi", "liboliphaunt-native:finalize-runtime-ios-abi"]' | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-planned-moon-job.sh liboliphaunt-native-release-assets | |
| - name: Upload aggregate liboliphaunt release assets | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: liboliphaunt-native-release-assets | |
| path: target/liboliphaunt/release-assets | |
| if-no-files-found: error | |
| rust-sdk-package: | |
| name: Builds / Rust SDK Package | |
| needs: | |
| - affected | |
| - checks | |
| - tests | |
| if: ${{ contains(fromJson(needs.affected.outputs.jobs), 'rust-sdk-package') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 90 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| - name: Set up Rust | |
| uses: ./.github/actions/setup-rust | |
| - name: Build Rust SDK package artifacts | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-planned-moon-job.sh rust-sdk-package | |
| - name: Upload Rust SDK package artifacts | |
| if: ${{ contains(join(fromJson(needs.affected.outputs.job_targets)['rust-sdk-package'], ','), 'oliphaunt-rust:') }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: oliphaunt-rust-sdk-package-artifacts | |
| path: target/sdk-artifacts/oliphaunt-rust | |
| if-no-files-found: error | |
| - name: Upload shared Rust query package | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: oliphaunt-query-sdk-package-artifacts | |
| path: target/sdk-artifacts/oliphaunt-query | |
| if-no-files-found: error | |
| - name: Upload native Rust bindings package | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: liboliphaunt-native-bindings-sdk-package-artifacts | |
| path: target/sdk-artifacts/liboliphaunt-native-bindings | |
| if-no-files-found: error | |
| - name: Upload broker source package | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: oliphaunt-broker-sdk-package-artifacts | |
| path: target/sdk-artifacts/oliphaunt-broker | |
| if-no-files-found: error | |
| - name: Build native extension lifecycle proof runner | |
| if: ${{ contains(fromJson(needs.affected.outputs.jobs), 'native-extension-lifecycle') }} | |
| run: cargo build --locked --release -p oliphaunt-native-extension-proof | |
| - name: Stage native extension lifecycle proof runner | |
| if: ${{ contains(fromJson(needs.affected.outputs.jobs), 'native-extension-lifecycle') }} | |
| run: | | |
| install -D -m 0755 \ | |
| target/release/oliphaunt-native-extension-proof \ | |
| target/native-extension-proof/oliphaunt-native-extension-proof | |
| - name: Upload native extension lifecycle proof runner | |
| if: ${{ contains(fromJson(needs.affected.outputs.jobs), 'native-extension-lifecycle') }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: oliphaunt-native-extension-proof-linux-x64-gnu | |
| path: | | |
| target/native-extension-proof/oliphaunt-native-extension-proof | |
| target/native-extension-proof/oliphaunt-rust-release-consumer | |
| if-no-files-found: error | |
| broker-runtime-linux: | |
| needs: [affected, checks, tests] | |
| if: ${{ fromJson(needs.affected.outputs.broker_runtime_matrix_linux).include[0] != null }} | |
| uses: ./.github/workflows/broker-runtime.yml | |
| with: | |
| matrix: ${{ needs.affected.outputs.broker_runtime_matrix_linux }} | |
| job-targets: ${{ needs.affected.outputs.job_targets }} | |
| broker-runtime-other: | |
| needs: [affected, checks, tests] | |
| if: ${{ fromJson(needs.affected.outputs.broker_runtime_matrix_other).include[0] != null }} | |
| uses: ./.github/workflows/broker-runtime.yml | |
| with: | |
| matrix: ${{ needs.affected.outputs.broker_runtime_matrix_other }} | |
| job-targets: ${{ needs.affected.outputs.job_targets }} | |
| broker-runtime: | |
| name: Builds / broker-runtime | |
| needs: [affected, broker-runtime-linux, broker-runtime-other] | |
| if: ${{ !cancelled() && !failure() && contains(fromJson(needs.affected.outputs.jobs), 'broker-runtime') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 5 | |
| steps: | |
| - name: Check selected platform producers | |
| env: | |
| RESULTS: ${{ join(needs.*.result, ',') }} | |
| run: | | |
| case ",$RESULTS," in | |
| *,failure,*|*,cancelled,*) exit 1 ;; | |
| esac | |
| node-direct: | |
| name: Builds / Node.js Direct (${{ matrix.target }}) | |
| needs: | |
| - affected | |
| - checks | |
| - tests | |
| if: ${{ contains(fromJson(needs.affected.outputs.jobs), 'node-direct') }} | |
| strategy: | |
| fail-fast: false | |
| matrix: ${{ fromJson(needs.affected.outputs.node_direct_runtime_matrix) }} | |
| runs-on: ${{ matrix.runner }} | |
| timeout-minutes: 45 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| - name: Set up Rust | |
| uses: ./.github/actions/setup-rust | |
| - name: Set up MSVC | |
| if: ${{ runner.os == 'Windows' }} | |
| uses: ./.github/actions/setup-msvc | |
| - name: Build Node direct release asset | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-planned-moon-job.sh node-direct | |
| - name: Upload Node direct release assets | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: oliphaunt-node-direct-release-assets-${{ matrix.target }} | |
| path: target/oliphaunt-node-direct/release-assets | |
| if-no-files-found: error | |
| - name: Upload Node direct optional npm package | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: oliphaunt-node-direct-npm-package-${{ matrix.target }} | |
| path: target/oliphaunt-node-direct/npm-packages/*.tgz | |
| if-no-files-found: error | |
| broker-release-assets: | |
| name: Builds / Broker Release Assets | |
| needs: | |
| - affected | |
| - broker-runtime | |
| if: ${{ !cancelled() && !failure() && needs.affected.result == 'success' && needs.broker-runtime.result == 'success' && contains(fromJson(needs.affected.outputs.jobs), 'broker-release-assets') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 15 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| - name: Download broker target release assets | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| pattern: oliphaunt-broker-release-assets-* | |
| path: target/oliphaunt-broker/release-assets | |
| merge-multiple: true | |
| - name: Verify aggregate broker release assets | |
| id: verify_aggregate_broker_release_assets | |
| env: | |
| OLIPHAUNT_MOON_TRANSFERRED_DEPS_JSON: '["oliphaunt-broker:build-release-assets"]' | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-planned-moon-job.sh broker-release-assets | |
| node-direct-release-assets: | |
| name: Builds / Node.js Direct Release Assets | |
| needs: | |
| - affected | |
| - node-direct | |
| if: ${{ !cancelled() && !failure() && needs.affected.result == 'success' && needs.node-direct.result == 'success' && contains(fromJson(needs.affected.outputs.jobs), 'node-direct-release-assets') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 15 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| - name: Download Node direct target release assets | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| pattern: oliphaunt-node-direct-release-assets-* | |
| path: target/oliphaunt-node-direct/release-assets | |
| merge-multiple: true | |
| - name: Download Node direct optional npm packages | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| pattern: oliphaunt-node-direct-npm-package-* | |
| path: target/oliphaunt-node-direct/npm-packages | |
| merge-multiple: true | |
| - name: Verify aggregate Node direct release assets | |
| id: verify_aggregate_node_direct_release_assets | |
| env: | |
| OLIPHAUNT_MOON_TRANSFERRED_DEPS_JSON: '["oliphaunt-node-direct:build-release-assets"]' | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-planned-moon-job.sh node-direct-release-assets | |
| wasix-napi: | |
| name: Builds / WASIX Node-API (${{ matrix.target }}) | |
| needs: | |
| - affected | |
| - extension-artifacts-wasix | |
| - liboliphaunt-wasix-aot | |
| - liboliphaunt-wasix-runtime | |
| if: ${{ !cancelled() && !failure() && needs.affected.result == 'success' && needs.extension-artifacts-wasix.result == 'success' && needs.liboliphaunt-wasix-aot.result == 'success' && needs.liboliphaunt-wasix-runtime.result == 'success' && contains(fromJson(needs.affected.outputs.jobs), 'wasix-napi') }} | |
| strategy: | |
| fail-fast: false | |
| matrix: ${{ fromJson(needs.affected.outputs.wasix_napi_runtime_matrix) }} | |
| runs-on: ${{ matrix.runner }} | |
| timeout-minutes: 180 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| - name: Set up Rust | |
| uses: ./.github/actions/setup-rust | |
| - name: Set up MSVC | |
| if: ${{ runner.os == 'Windows' }} | |
| uses: ./.github/actions/setup-msvc | |
| - name: Download same-run portable WASIX outputs | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-wasix-runtime-portable | |
| path: . | |
| - name: Download same-run WASIX exact-extension outputs | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| pattern: liboliphaunt-wasix-extension-artifacts-* | |
| path: target/extensions/wasix/release-assets | |
| merge-multiple: true | |
| - name: Download same-run target extension AOT outputs | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-wasix-extension-aot-${{ matrix.target }} | |
| path: target/extensions/wasix/aot-artifacts | |
| - name: Download same-run target core and tool AOT outputs | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-wasix-runtime-aot-${{ matrix.target }} | |
| path: target/oliphaunt-wasix/napi-aot-download | |
| - name: Restore exact target core and tool AOT layout | |
| shell: bash | |
| env: | |
| EXPECTED_TARGET_TRIPLE: ${{ matrix.target_triple }} | |
| run: | | |
| artifact_dir=target/oliphaunt-wasix/napi-aot-download | |
| marker="$artifact_dir/target-triple.txt" | |
| raw_target_dir="$artifact_dir/files" | |
| if [[ ! -f "$marker" || ! -d "$raw_target_dir" ]]; then | |
| echo "invalid WASIX N-API AOT artifact envelope in $artifact_dir" >&2 | |
| exit 1 | |
| fi | |
| target="$(tr -d '\r\n' < "$marker")" | |
| if [[ "$target" != "${EXPECTED_TARGET_TRIPLE:?EXPECTED_TARGET_TRIPLE is required}" ]]; then | |
| echo "WASIX N-API AOT artifact targets $target, expected $EXPECTED_TARGET_TRIPLE" >&2 | |
| exit 1 | |
| fi | |
| destination="target/oliphaunt-wasix/aot/$target" | |
| mkdir -p "$destination" | |
| cp -R "$raw_target_dir/." "$destination/" | |
| - name: Set up macOS smoke timeout | |
| if: ${{ runner.os == 'macOS' }} | |
| shell: bash | |
| run: brew list coreutils >/dev/null 2>&1 || HOMEBREW_NO_AUTO_UPDATE=1 brew install coreutils | |
| - name: Build WASIX Node-API release assets | |
| shell: bash | |
| env: | |
| OLIPHAUNT_ARTIFACT_CRATE_REQUIRE_PAYLOAD: "1" | |
| OLIPHAUNT_ICU_DATA_DIR: ${{ github.workspace }}/target/oliphaunt-wasix/wasix-build/work/icu-wasix/share/icu | |
| OLIPHAUNT_WASM_GENERATED_AOT_DIR: ${{ github.workspace }}/target/oliphaunt-wasix/aot | |
| OLIPHAUNT_WASIX_EXTENSION_ARTIFACT_ROOT: ${{ github.workspace }}/target/extension-artifacts | |
| OLIPHAUNT_WASIX_GENERATED_ASSETS_DIR: ${{ github.workspace }}/target/oliphaunt-wasix/assets | |
| OLIPHAUNT_WASIX_NAPI_ARTIFACT_SOURCE_SHA: ${{ github.event.pull_request.head.sha || github.sha }} | |
| OLIPHAUNT_MOON_TRANSFERRED_DEPS_JSON: '["extension-artifacts-wasix:build-target", "extension-artifacts-wasix:build-aot", "liboliphaunt-wasix:runtime-aot"]' | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-planned-moon-job.sh wasix-napi | |
| - name: Upload WASIX Node-API release assets | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: oliphaunt-wasix-napi-release-assets-${{ matrix.target }} | |
| path: target/oliphaunt-wasix-napi/release-assets | |
| if-no-files-found: error | |
| - name: Upload WASIX Node-API optional npm package | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: oliphaunt-wasix-napi-npm-package-${{ matrix.target }} | |
| path: target/oliphaunt-wasix-napi/npm-packages/*.tgz | |
| if-no-files-found: error | |
| wasix-napi-release-assets: | |
| name: Builds / WASIX Node-API Release Assets | |
| needs: | |
| - affected | |
| - wasix-napi | |
| if: ${{ !cancelled() && !failure() && needs.affected.result == 'success' && needs.wasix-napi.result == 'success' && contains(fromJson(needs.affected.outputs.jobs), 'wasix-napi-release-assets') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 15 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| - name: Download WASIX Node-API target release assets | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| pattern: oliphaunt-wasix-napi-release-assets-* | |
| path: target/oliphaunt-wasix-napi/release-assets | |
| merge-multiple: true | |
| - name: Download WASIX Node-API optional npm packages | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| pattern: oliphaunt-wasix-napi-npm-package-* | |
| path: target/oliphaunt-wasix-napi/npm-packages | |
| merge-multiple: true | |
| - name: Verify aggregate WASIX Node-API release assets | |
| id: verify_aggregate_wasix_napi_release_assets | |
| env: | |
| OLIPHAUNT_MOON_TRANSFERRED_DEPS_JSON: '["oliphaunt-wasix-napi:build-release-assets"]' | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-planned-moon-job.sh wasix-napi-release-assets | |
| swift-bindings: | |
| name: Builds / Swift Native Bindings | |
| needs: [affected, checks, tests] | |
| if: ${{ contains(fromJson(needs.affected.outputs.jobs), 'swift-bindings') }} | |
| runs-on: macos-26 | |
| timeout-minutes: 30 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| - name: Set up Rust | |
| uses: ./.github/actions/setup-rust | |
| - name: Install Apple Rust targets | |
| run: rustup target add aarch64-apple-ios aarch64-apple-ios-sim aarch64-apple-darwin | |
| - name: Select Apple framework toolchain | |
| uses: ./.github/actions/setup-apple | |
| with: | |
| install-build-dependencies: "false" | |
| - name: Build Swift native bindings | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-planned-moon-job.sh swift-bindings | |
| - name: Upload Swift bindings and generated source | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: oliphaunt-swift-bindings | |
| path: | | |
| target/oliphaunt-swift/release-assets | |
| target/mobile-bindings/generated | |
| if-no-files-found: error | |
| swift-sdk-package: | |
| name: Builds / Swift SDK Package | |
| needs: | |
| - affected | |
| - liboliphaunt-native-ios-abi | |
| - swift-bindings | |
| if: ${{ contains(fromJson(needs.affected.outputs.jobs), 'swift-sdk-package') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 90 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| - name: Download Apple liboliphaunt release assets | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-native-abi-compatible-release-assets-ios-datum64 | |
| path: target/liboliphaunt/abi-compatible-release-assets/ios-datum64 | |
| - name: Download Swift bindings and generated source | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: oliphaunt-swift-bindings | |
| path: target | |
| - name: Build Swift SDK package artifacts | |
| env: | |
| OLIPHAUNT_SWIFT_RELEASE_ASSET_DIR: ${{ github.workspace }}/target/liboliphaunt/abi-compatible-release-assets/ios-datum64 | |
| OLIPHAUNT_MOON_TRANSFERRED_DEPS_JSON: '["liboliphaunt-native:finalize-runtime-ios-abi", "oliphaunt-swift:package-bindings"]' | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-planned-moon-job.sh swift-sdk-package | |
| - name: Upload Swift SDK package artifacts | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: oliphaunt-swift-sdk-package-artifacts | |
| path: target/sdk-artifacts/oliphaunt-swift | |
| if-no-files-found: error | |
| kotlin-sdk-package: | |
| name: Builds / Kotlin SDK Package | |
| needs: | |
| - affected | |
| - checks | |
| - tests | |
| if: ${{ contains(fromJson(needs.affected.outputs.jobs), 'kotlin-sdk-package') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 90 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| - name: Set up Rust | |
| uses: ./.github/actions/setup-rust | |
| - name: Install Android Rust targets | |
| run: rustup target add aarch64-linux-android x86_64-linux-android | |
| - name: Set up Android | |
| uses: ./.github/actions/setup-android | |
| with: | |
| gradle-cache-save-if: ${{ env.HEAVY_CACHE_SAVE_IF }} | |
| - name: Build Kotlin SDK package artifacts | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-planned-moon-job.sh kotlin-sdk-package | |
| - name: Upload Kotlin SDK package artifacts | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: oliphaunt-kotlin-sdk-package-artifacts | |
| path: target/sdk-artifacts/oliphaunt-kotlin | |
| if-no-files-found: error | |
| kotlin-maven-staging: | |
| name: Builds / Kotlin SDK Maven Staging | |
| needs: | |
| - affected | |
| - kotlin-sdk-package | |
| if: ${{ !cancelled() && !failure() && needs.affected.result == 'success' && needs.kotlin-sdk-package.result == 'success' && contains(fromJson(needs.affected.outputs.jobs), 'kotlin-maven-staging') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 10 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| - name: Download exact same-run Kotlin SDK package artifacts | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: oliphaunt-kotlin-sdk-package-artifacts | |
| path: target/sdk-artifacts/oliphaunt-kotlin | |
| - name: Validate exact Kotlin Maven Central staging closure | |
| id: kotlin_maven_staging | |
| env: | |
| OLIPHAUNT_MOON_TRANSFERRED_DEPS_JSON: '["oliphaunt-kotlin:package"]' | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-planned-moon-job.sh kotlin-maven-staging | |
| react-native-sdk-package: | |
| name: Builds / React Native SDK Package | |
| needs: | |
| - affected | |
| - liboliphaunt-native-ios-abi | |
| if: ${{ contains(fromJson(needs.affected.outputs.jobs), 'react-native-sdk-package') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 90 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| with: | |
| install-workspace: "true" | |
| - name: Download Apple liboliphaunt release assets | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-native-abi-compatible-release-assets-ios-datum64 | |
| path: target/liboliphaunt/abi-compatible-release-assets/ios-datum64 | |
| - name: Build React Native SDK package artifacts | |
| env: | |
| OLIPHAUNT_REACT_NATIVE_IOS_RELEASE_ASSET_DIR: ${{ github.workspace }}/target/liboliphaunt/abi-compatible-release-assets/ios-datum64 | |
| OLIPHAUNT_MOON_TRANSFERRED_DEPS_JSON: '["liboliphaunt-native:finalize-runtime-ios-abi"]' | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-planned-moon-job.sh react-native-sdk-package | |
| - name: Upload React Native SDK package artifacts | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: oliphaunt-react-native-sdk-package-artifacts | |
| path: target/sdk-artifacts/oliphaunt-react-native | |
| if-no-files-found: error | |
| js-sdk-package: | |
| name: Builds / JavaScript SDK Package | |
| permissions: | |
| contents: read | |
| actions: read | |
| outputs: | |
| producer_receipt: ${{ steps.query_producer_receipt.outputs.receipt }} | |
| needs: | |
| - affected | |
| - checks | |
| - tests | |
| if: ${{ contains(fromJson(needs.affected.outputs.jobs), 'js-sdk-package') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 60 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| with: | |
| install-workspace: "true" | |
| - name: Set up Deno | |
| uses: ./.github/actions/setup-deno | |
| with: | |
| deno-version: ${{ env.DENO_VERSION }} | |
| - name: Build TypeScript SDK package artifacts | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-planned-moon-job.sh js-sdk-package | |
| - name: Upload JS SDK package artifacts | |
| if: ${{ contains(join(fromJson(needs.affected.outputs.job_targets)['js-sdk-package'], ','), 'oliphaunt-js:') }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: oliphaunt-js-sdk-package-artifacts | |
| path: target/sdk-artifacts/oliphaunt-js | |
| if-no-files-found: error | |
| - name: Upload PostgreSQL WASIX tools facade | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['js-sdk-package'], 'oliphaunt-wasix-tools-ts:package') }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: postgres-tools-wasix-package-artifacts | |
| path: target/sdk-artifacts/postgres-tools-wasix | |
| if-no-files-found: error | |
| - name: Upload canonical ICU data | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['js-sdk-package'], 'database-resources:package-icu') }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: database-resources-icu-data-portable | |
| path: target/database-resources/release-assets/*-icu-data.tar.gz | |
| if-no-files-found: error | |
| - name: Upload canonical ICU npm carrier | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['js-sdk-package'], 'database-resources:package-icu') }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: database-resources-icu-npm | |
| path: target/release/npm-packages/oliphaunt-icu/*.tgz | |
| if-no-files-found: error | |
| - name: Upload shared TypeScript query package | |
| id: query_package_artifact | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['js-sdk-package'], 'oliphaunt-query-ts:package') }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: oliphaunt-query-ts-sdk-package-artifacts | |
| path: target/sdk-artifacts/oliphaunt-query-ts | |
| if-no-files-found: error | |
| - name: Record TypeScript query producer evidence | |
| id: query_producer_receipt | |
| if: ${{ steps.query_package_artifact.outcome == 'success' }} | |
| env: | |
| GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| CI_HEAD_SHA: ${{ github.event.pull_request.head.sha || github.sha }} | |
| PRODUCER_ARTIFACT_ID: ${{ steps.query_package_artifact.outputs.artifact-id }} | |
| PRODUCER_ARTIFACT_DIGEST: ${{ steps.query_package_artifact.outputs.artifact-digest }} | |
| run: | | |
| PRODUCER_MOON_VERSION="$(moon --version)" | |
| export PRODUCER_MOON_VERSION | |
| bun .github/scripts/moon-producer-receipt.mts oliphaunt-query-ts:package oliphaunt-query-ts-sdk-package-artifacts sdks/ts-query | |
| native-consumers: | |
| name: Builds / Native Product Consumers | |
| needs: [affected, js-sdk-package, liboliphaunt-native-desktop, broker-runtime, node-direct] | |
| if: ${{ !cancelled() && !failure() && needs.affected.result == 'success' && contains(fromJson(needs.affected.outputs.jobs), 'native-consumers') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 20 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| with: | |
| install-workspace: "true" | |
| - name: Set up Deno | |
| uses: ./.github/actions/setup-deno | |
| with: | |
| deno-version: ${{ env.DENO_VERSION }} | |
| - name: Set up Rust | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['native-consumers'], 'oliphaunt-broker:test-consumer') }} | |
| uses: ./.github/actions/setup-rust | |
| - name: Download SDK package | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['native-consumers'], 'oliphaunt-js:test-consumer') || contains(fromJson(needs.affected.outputs.job_targets)['native-consumers'], 'oliphaunt-js:test-consumer-published') }} | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: oliphaunt-js-sdk-package-artifacts | |
| path: target/sdk-artifacts/oliphaunt-js | |
| - name: Download query dependency package | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['native-consumers'], 'oliphaunt-js:test-consumer') }} | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: oliphaunt-query-ts-sdk-package-artifacts | |
| path: target/sdk-artifacts/oliphaunt-query-ts | |
| - name: Download Linux runtime archive | |
| if: ${{ !contains(fromJson(needs.affected.outputs.job_targets)['native-consumers'], 'oliphaunt-js:test-consumer-published') }} | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-native-release-assets-linux-x64-gnu | |
| path: target/liboliphaunt/desktop-release-assets/linux-x64-gnu | |
| - name: Download Linux broker archive | |
| if: ${{ !contains(fromJson(needs.affected.outputs.job_targets)['native-consumers'], 'oliphaunt-js:test-consumer-published') }} | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: oliphaunt-broker-release-assets-linux-x64-gnu | |
| path: target/oliphaunt-broker/release-assets | |
| - name: Download Linux addon archive | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['native-consumers'], 'oliphaunt-js:test-consumer') }} | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: oliphaunt-node-direct-release-assets-linux-x64-gnu | |
| path: target/oliphaunt-node-direct/release-assets | |
| - name: Exercise selected products against shipped native artifacts | |
| env: | |
| OLIPHAUNT_PUBLISHED_DEPENDENCIES: ${{ needs.affected.outputs.published_dependencies }} | |
| OLIPHAUNT_MOON_TRANSFERRED_DEPS_JSON: '["oliphaunt-js:package", "oliphaunt-query-ts:package", "liboliphaunt-native:package-runtime-desktop-target", "oliphaunt-broker:build-release-assets", "oliphaunt-node-direct:build-release-assets"]' | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-planned-moon-job.sh native-consumers | |
| wasix-ts-sdk-package: | |
| name: Builds / WASIX TypeScript SDK | |
| needs: | |
| - affected | |
| - liboliphaunt-wasix-runtime | |
| - wasix-napi | |
| - js-sdk-package | |
| - liboliphaunt-wasix-aot | |
| if: ${{ !cancelled() && !failure() && needs.affected.result == 'success' && needs.liboliphaunt-wasix-runtime.result == 'success' && (!contains(fromJson(needs.affected.outputs.jobs), 'wasix-napi') || needs.wasix-napi.result == 'success') && (!contains(fromJson(needs.affected.outputs.jobs), 'js-sdk-package') || needs.js-sdk-package.result == 'success') && (!contains(fromJson(needs.affected.outputs.jobs), 'liboliphaunt-wasix-aot') || needs.liboliphaunt-wasix-aot.result == 'success') && contains(fromJson(needs.affected.outputs.jobs), 'wasix-ts-sdk-package') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 120 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| with: | |
| install-workspace: "true" | |
| - name: Set up Rust and wasm-pack | |
| uses: ./.github/actions/setup-rust | |
| with: | |
| tools: wasm-pack@0.15.0 | |
| - name: Set up Deno | |
| uses: ./.github/actions/setup-deno | |
| with: | |
| deno-version: ${{ env.DENO_VERSION }} | |
| - name: Download same-run portable WASIX outputs | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-wasix-runtime-portable | |
| path: . | |
| - name: Download same-run Linux x64 WASIX Node-API carrier | |
| if: ${{ contains(fromJson(needs.affected.outputs.jobs), 'wasix-napi') }} | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: oliphaunt-wasix-napi-npm-package-linux-x64-gnu | |
| path: target/oliphaunt-wasix-napi/npm-packages | |
| - name: Download tools facade package | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['wasix-ts-sdk-package'], 'postgres-tools-wasix:test-consumer') || contains(fromJson(needs.affected.outputs.job_targets)['wasix-ts-sdk-package'], 'postgres-tools-wasix:test-browser') }} | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: postgres-tools-wasix-package-artifacts | |
| path: target/sdk-artifacts/postgres-tools-wasix | |
| - name: Download portable PostgreSQL tools | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['wasix-ts-sdk-package'], 'postgres-tools-wasix:test-consumer') || contains(fromJson(needs.affected.outputs.job_targets)['wasix-ts-sdk-package'], 'postgres-tools-wasix:test-browser') }} | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: postgres-tools-wasix-release-assets-portable | |
| path: target/postgres-tools/wasix/release-assets | |
| - name: Download native PostgreSQL tools AOT | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['wasix-ts-sdk-package'], 'postgres-tools-wasix:test-consumer') }} | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: postgres-tools-wasix-release-assets-linux-x64-gnu | |
| path: target/postgres-tools/wasix/release-assets | |
| - name: Download same-run WASIX extension compiler outputs | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-wasix-runtime'], 'extension-artifacts-wasix:compiler-output') }} | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: extensions-wasix-compiler-output | |
| path: target/extensions/wasix/assets | |
| - name: Download same-run WASIX seeds | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-wasix-runtime'], 'database-resources:build-wasix-standard') || contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-wasix-runtime'], 'database-resources:build-wasix-icu') }} | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: database-resources-wasix-seeds-portable | |
| path: target/database-resources/release-assets | |
| - name: Download same-run ICU npm carrier | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['js-sdk-package'], 'database-resources:package-icu') }} | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: database-resources-icu-npm | |
| path: target/release/npm-packages/oliphaunt-icu | |
| - name: Build, test, and package the WASIX TypeScript SDK | |
| env: | |
| OLIPHAUNT_MOON_TRANSFERRED_DEPS_JSON: '["liboliphaunt-wasix:runtime-portable", "extension-artifacts-wasix:compiler-output", "database-resources:build-wasix-standard", "database-resources:build-wasix-icu", "database-resources:package-icu", "oliphaunt-wasix-napi:build-release-assets", "oliphaunt-wasix-tools-ts:package", "postgres-tools-wasix:package-portable", "postgres-tools-wasix:package-aot"]' | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-planned-moon-job.sh wasix-ts-sdk-package | |
| - name: Upload WASIX TypeScript SDK package artifacts | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['wasix-ts-sdk-package'], 'oliphaunt-wasix-ts:package') }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: oliphaunt-wasix-ts-sdk-package-artifacts | |
| path: target/sdk-artifacts/oliphaunt-wasix-ts | |
| if-no-files-found: error | |
| wasix-rust-package: | |
| name: Builds / WASIX Rust Binding Package | |
| needs: | |
| - affected | |
| - checks | |
| - tests | |
| if: ${{ contains(fromJson(needs.affected.outputs.jobs), 'wasix-rust-package') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 90 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| with: | |
| install-workspace: "true" | |
| - name: Set up Rust | |
| uses: ./.github/actions/setup-rust | |
| - name: Build Rust WASIX binding package artifacts | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-planned-moon-job.sh wasix-rust-package | |
| - name: Upload Rust WASIX binding package artifacts | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['wasix-rust-package'], 'oliphaunt-wasix-rust:package') }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: oliphaunt-wasix-rust-package-artifacts | |
| path: target/sdk-artifacts/oliphaunt-wasix-rust | |
| if-no-files-found: error | |
| - name: Upload PGwire server package artifacts | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['wasix-rust-package'], 'oliphaunt-pgwire-server:package') }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: oliphaunt-pgwire-server-sdk-package-artifacts | |
| path: target/sdk-artifacts/oliphaunt-pgwire-server | |
| if-no-files-found: error | |
| liboliphaunt-wasix-runtime: | |
| name: Builds / liboliphaunt WASIX Runtime | |
| needs: | |
| - affected | |
| - checks | |
| - tests | |
| if: ${{ contains(fromJson(needs.affected.outputs.jobs), 'liboliphaunt-wasix-runtime') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 360 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| - name: Set up Rust | |
| uses: ./.github/actions/setup-rust | |
| with: | |
| cache-save-if: ${{ env.HEAVY_CACHE_SAVE_IF }} | |
| - name: Restore WASIX compilation cache | |
| id: wasix-build-cache | |
| uses: actions/cache/restore@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 | |
| with: | |
| path: | | |
| target/liboliphaunt-pg18/source | |
| target/oliphaunt-wasix/wasix-build/source-cache | |
| target/oliphaunt-wasix/wasix-build/work/docker-oliphaunt | |
| target/oliphaunt-wasix/wasix-build/work/icu-native | |
| target/oliphaunt-wasix/wasix-build/work/icu-wasix | |
| target/oliphaunt-wasix/wasix-build/work/icu-wasix-build | |
| target/oliphaunt-wasix/wasix-build/work/json-c-wasix | |
| target/oliphaunt-wasix/wasix-build/work/json-c-wasix-build | |
| target/oliphaunt-wasix/wasix-build/work/libiconv-wasix | |
| target/oliphaunt-wasix/wasix-build/work/libiconv-wasix-build | |
| target/oliphaunt-wasix/wasix-build/work/libxml2-wasix | |
| target/oliphaunt-wasix/wasix-build/work/libxml2-wasix-build | |
| target/oliphaunt-wasix/wasix-build/work/openssl-wasix | |
| target/oliphaunt-wasix/wasix-build/work/openssl-wasix-build | |
| target/oliphaunt-wasix/wasix-build/work/proj-wasix | |
| target/oliphaunt-wasix/wasix-build/work/proj-wasix-build | |
| target/oliphaunt-wasix/wasix-build/work/sqlite-wasix | |
| target/oliphaunt-wasix/wasix-build/work/sqlite-wasix-build | |
| target/oliphaunt-wasix/wasix-build/work/geos-wasix | |
| target/oliphaunt-wasix/wasix-build/work/geos-wasix-build | |
| target/oliphaunt-wasix/wasix-build/build | |
| key: wasix-build-${{ runner.os }}-${{ env.ASSET_PROFILE }}-${{ env.WASMER_LLVM_VERSION }}-${{ env.WASMER_LLVM_LINUX_X64_BYTES }}-${{ env.WASMER_LLVM_LINUX_X64_SHA256 }}-${{ github.event.pull_request.head.sha || github.sha }} | |
| restore-keys: | | |
| wasix-build-${{ runner.os }}-${{ env.ASSET_PROFILE }}-${{ env.WASMER_LLVM_VERSION }}-${{ env.WASMER_LLVM_LINUX_X64_BYTES }}-${{ env.WASMER_LLVM_LINUX_X64_SHA256 }}-${{ github.event.pull_request.base.sha || github.event.before || github.sha }} | |
| - name: Set up Docker Buildx | |
| uses: docker/setup-buildx-action@4d04d5d9486b7bd6fa91e7baf45bbb4f8b9deedd | |
| - name: Build WASIX builder image and save cache | |
| if: ${{ env.HEAVY_CACHE_SAVE_IF == 'true' }} | |
| uses: docker/build-push-action@bcafcacb16a39f128d818304e6c9c0c18556b85f | |
| with: | |
| context: runtimes/liboliphaunt-wasix/assets/build/docker | |
| file: runtimes/liboliphaunt-wasix/assets/build/docker/Dockerfile | |
| tags: oliphaunt-wasix-wasix-build:ci | |
| load: true | |
| cache-from: type=gha,scope=wasix-builder | |
| cache-to: type=gha,mode=max,scope=wasix-builder,ignore-error=true | |
| - name: Build WASIX builder image | |
| if: ${{ env.HEAVY_CACHE_SAVE_IF != 'true' }} | |
| uses: docker/build-push-action@bcafcacb16a39f128d818304e6c9c0c18556b85f | |
| with: | |
| context: runtimes/liboliphaunt-wasix/assets/build/docker | |
| file: runtimes/liboliphaunt-wasix/assets/build/docker/Dockerfile | |
| tags: oliphaunt-wasix-wasix-build:ci | |
| load: true | |
| cache-from: type=gha,scope=wasix-builder | |
| - name: Install Wasmer LLVM 22.1 for WASIX cluster-seed generation | |
| uses: ./.github/actions/setup-wasmer-llvm | |
| with: | |
| url: ${{ env.WASMER_LLVM_LINUX_X64_URL }} | |
| sha256: ${{ env.WASMER_LLVM_LINUX_X64_SHA256 }} | |
| bytes: ${{ env.WASMER_LLVM_LINUX_X64_BYTES }} | |
| version: ${{ env.WASMER_LLVM_VERSION }} | |
| cache-save-if: ${{ env.HEAVY_CACHE_SAVE_IF }} | |
| - name: Build and validate portable WASIX runtime | |
| env: | |
| IMAGE: oliphaunt-wasix-wasix-build:ci | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-planned-moon-job.sh liboliphaunt-wasix-runtime | |
| - name: Save WASIX compilation cache | |
| id: save_wasix_build_cache | |
| if: ${{ env.HEAVY_CACHE_SAVE_IF == 'true' && steps.wasix-build-cache.outputs.cache-hit != 'true' }} | |
| continue-on-error: true | |
| uses: actions/cache/save@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 | |
| with: | |
| path: | | |
| target/liboliphaunt-pg18/source | |
| target/oliphaunt-wasix/wasix-build/source-cache | |
| target/oliphaunt-wasix/wasix-build/work/docker-oliphaunt | |
| target/oliphaunt-wasix/wasix-build/work/icu-native | |
| target/oliphaunt-wasix/wasix-build/work/icu-wasix | |
| target/oliphaunt-wasix/wasix-build/work/icu-wasix-build | |
| target/oliphaunt-wasix/wasix-build/work/json-c-wasix | |
| target/oliphaunt-wasix/wasix-build/work/json-c-wasix-build | |
| target/oliphaunt-wasix/wasix-build/work/libiconv-wasix | |
| target/oliphaunt-wasix/wasix-build/work/libiconv-wasix-build | |
| target/oliphaunt-wasix/wasix-build/work/libxml2-wasix | |
| target/oliphaunt-wasix/wasix-build/work/libxml2-wasix-build | |
| target/oliphaunt-wasix/wasix-build/work/openssl-wasix | |
| target/oliphaunt-wasix/wasix-build/work/openssl-wasix-build | |
| target/oliphaunt-wasix/wasix-build/work/proj-wasix | |
| target/oliphaunt-wasix/wasix-build/work/proj-wasix-build | |
| target/oliphaunt-wasix/wasix-build/work/sqlite-wasix | |
| target/oliphaunt-wasix/wasix-build/work/sqlite-wasix-build | |
| target/oliphaunt-wasix/wasix-build/work/geos-wasix | |
| target/oliphaunt-wasix/wasix-build/work/geos-wasix-build | |
| target/oliphaunt-wasix/wasix-build/build | |
| key: wasix-build-${{ runner.os }}-${{ env.ASSET_PROFILE }}-${{ env.WASMER_LLVM_VERSION }}-${{ env.WASMER_LLVM_LINUX_X64_BYTES }}-${{ env.WASMER_LLVM_LINUX_X64_SHA256 }}-${{ github.event.pull_request.head.sha || github.sha }} | |
| - name: Upload portable WASIX tools compiler outputs | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-wasix-runtime'], 'postgres-tools-wasix:compiler-output') }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: postgres-tools-wasix-compiler-output | |
| path: target/postgres-tools/wasix/assets | |
| if-no-files-found: error | |
| - name: Upload portable WASIX extension compiler outputs | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-wasix-runtime'], 'extension-artifacts-wasix:compiler-output') }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: extensions-wasix-compiler-output | |
| path: target/extensions/wasix/assets | |
| if-no-files-found: error | |
| - name: Upload portable PostgreSQL WASIX tools | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-wasix-runtime'], 'postgres-tools-wasix:package-portable') }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: postgres-tools-wasix-release-assets-portable | |
| path: target/postgres-tools/wasix/release-assets/*-portable.tar.gz | |
| if-no-files-found: error | |
| - name: Upload independent WASIX cluster seeds | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-wasix-runtime'], 'database-resources:build-wasix-standard') || contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-wasix-runtime'], 'database-resources:build-wasix-icu') }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: database-resources-wasix-seeds-portable | |
| path: target/database-resources/release-assets/*-seed-wasix-* | |
| if-no-files-found: error | |
| - name: Upload portable WASIX build outputs | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: liboliphaunt-wasix-runtime-portable | |
| path: | | |
| target/oliphaunt-wasix/wasix-build/build/** | |
| target/oliphaunt-wasix/wasix-build/work/icu-wasix/share/icu/** | |
| target/oliphaunt-wasix/assets/** | |
| extensions/generated/** | |
| runtimes/liboliphaunt-wasix/assets/generated/** | |
| if-no-files-found: error | |
| liboliphaunt-wasix-aot: | |
| name: Builds / liboliphaunt WASIX AOT (${{ matrix.target_id }}) | |
| needs: | |
| - affected | |
| - liboliphaunt-wasix-runtime | |
| if: ${{ contains(fromJson(needs.affected.outputs.jobs), 'liboliphaunt-wasix-aot') }} | |
| runs-on: ${{ matrix.os }} | |
| timeout-minutes: 180 | |
| strategy: | |
| fail-fast: false | |
| matrix: ${{ fromJson(needs.affected.outputs.liboliphaunt_wasix_aot_runtime_matrix || '{"include":[]}') }} | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| - name: Set up Rust | |
| uses: ./.github/actions/setup-rust | |
| - name: Set up MSVC | |
| if: ${{ runner.os == 'Windows' }} | |
| uses: ./.github/actions/setup-msvc | |
| - name: Download portable WASIX build outputs | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-wasix-runtime-portable | |
| path: . | |
| - name: Download portable WASIX tools compiler outputs | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-wasix-aot'], 'postgres-tools-wasix:build-aot') }} | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: postgres-tools-wasix-compiler-output | |
| path: target/postgres-tools/wasix/assets | |
| - name: Download portable WASIX extension compiler outputs | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-wasix-aot'], 'extension-artifacts-wasix:build-aot') }} | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: extensions-wasix-compiler-output | |
| path: target/extensions/wasix/assets | |
| - name: Install Wasmer LLVM 22.1 for AOT generation | |
| uses: ./.github/actions/setup-wasmer-llvm | |
| with: | |
| url: ${{ matrix.llvm_url }} | |
| sha256: ${{ matrix.llvm_sha256 }} | |
| bytes: ${{ matrix.llvm_bytes }} | |
| version: ${{ env.WASMER_LLVM_VERSION }} | |
| - name: Build, validate, and smoke target AOT artifacts | |
| env: | |
| AOT_TARGET: ${{ matrix.target }} | |
| OLIPHAUNT_MOON_TRANSFERRED_DEPS_JSON: '["liboliphaunt-wasix:runtime-portable", "postgres-tools-wasix:compiler-output", "extension-artifacts-wasix:compiler-output"]' | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-planned-moon-job.sh liboliphaunt-wasix-aot | |
| - name: Upload target PostgreSQL WASIX tools | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-wasix-aot'], 'postgres-tools-wasix:package-aot') }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: postgres-tools-wasix-release-assets-${{ matrix.target_id }} | |
| path: target/postgres-tools/wasix/release-assets/*-aot-${{ matrix.target_id }}.tar.gz | |
| if-no-files-found: error | |
| - name: Stage target AOT artifact envelope | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-wasix-aot'], 'liboliphaunt-wasix:runtime-aot') }} | |
| env: | |
| AOT_TARGET: ${{ matrix.target }} | |
| run: | | |
| target="${AOT_TARGET:?AOT_TARGET is required}" | |
| source="target/oliphaunt-wasix/aot/$target" | |
| if [ ! -d "$source" ]; then | |
| echo "missing AOT output directory: $source" >&2 | |
| exit 1 | |
| fi | |
| upload="target/oliphaunt-wasix/aot-upload" | |
| rm -rf "$upload" | |
| mkdir -p "$upload/files" | |
| cp -R "$source/." "$upload/files/" | |
| printf '%s\n' "$target" >"$upload/target-triple.txt" | |
| - name: Upload target artifacts | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-wasix-aot'], 'liboliphaunt-wasix:runtime-aot') }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: liboliphaunt-wasix-runtime-aot-${{ matrix.target_id }} | |
| path: | | |
| target/oliphaunt-wasix/aot-upload/** | |
| if-no-files-found: error | |
| - name: Upload target WASIX tools compiler outputs | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-wasix-aot'], 'postgres-tools-wasix:build-aot') }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: postgres-tools-wasix-aot-${{ matrix.target_id }} | |
| path: target/postgres-tools/wasix/aot | |
| if-no-files-found: error | |
| - name: Upload target extension AOT artifacts | |
| if: ${{ contains(fromJson(needs.affected.outputs.job_targets)['liboliphaunt-wasix-aot'], 'extension-artifacts-wasix:build-aot') }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: liboliphaunt-wasix-extension-aot-${{ matrix.target_id }} | |
| path: target/extensions/wasix/aot-artifacts | |
| if-no-files-found: error | |
| liboliphaunt-wasix-release-assets: | |
| name: Builds / liboliphaunt WASIX Release Assets | |
| needs: | |
| - affected | |
| - liboliphaunt-wasix-runtime | |
| - liboliphaunt-wasix-aot | |
| if: ${{ contains(fromJson(needs.affected.outputs.jobs), 'liboliphaunt-wasix-release-assets') && (github.event_name != 'workflow_dispatch' || inputs.wasm_target == 'all') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 30 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| - name: Set up Rust | |
| uses: ./.github/actions/setup-rust | |
| - name: Download portable WASIX runtime outputs | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-wasix-runtime-portable | |
| path: . | |
| - name: Download WASIX AOT runtime outputs | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| pattern: liboliphaunt-wasix-runtime-aot-* | |
| path: target/oliphaunt-wasix/aot-downloads | |
| - name: Restore WASIX AOT target layout | |
| run: | | |
| shopt -s nullglob | |
| for artifact_dir in target/oliphaunt-wasix/aot-downloads/liboliphaunt-wasix-runtime-aot-*; do | |
| marker="$artifact_dir/target-triple.txt" | |
| raw_target_dir="$artifact_dir/files" | |
| if [ ! -f "$marker" ] || [ ! -d "$raw_target_dir" ]; then | |
| echo "Invalid WASIX AOT artifact envelope in $artifact_dir" >&2 | |
| exit 1 | |
| fi | |
| target="$(tr -d '\r\n' < "$marker")" | |
| if [ -z "$target" ]; then | |
| echo "Empty WASIX AOT target marker in $marker" >&2 | |
| exit 1 | |
| fi | |
| destination="target/oliphaunt-wasix/aot/$target" | |
| mkdir -p "$destination" | |
| rsync -a "$raw_target_dir/" "$destination/" | |
| done | |
| - name: Package WASIX release assets | |
| env: | |
| OLIPHAUNT_MOON_TRANSFERRED_DEPS_JSON: '["liboliphaunt-wasix:runtime-portable", "liboliphaunt-wasix:runtime-aot"]' | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-planned-moon-job.sh liboliphaunt-wasix-release-assets | |
| - name: Upload WASIX release assets | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: liboliphaunt-wasix-release-assets | |
| path: target/oliphaunt-wasix/release-assets | |
| if-no-files-found: error | |
| wasix-postmaster-portable: | |
| name: Builds / WASIX Postmaster / Portable + qualification | |
| needs: | |
| - affected | |
| - checks | |
| - tests | |
| if: ${{ contains(fromJson(needs.affected.outputs.jobs), 'wasix-postmaster') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 240 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| - name: Set up Rust | |
| uses: ./.github/actions/setup-rust | |
| - name: Install Wasmer LLVM 22.1 | |
| uses: ./.github/actions/setup-wasmer-llvm | |
| with: | |
| url: ${{ env.WASMER_LLVM_LINUX_X64_URL }} | |
| sha256: ${{ env.WASMER_LLVM_LINUX_X64_SHA256 }} | |
| bytes: ${{ env.WASMER_LLVM_LINUX_X64_BYTES }} | |
| version: ${{ env.WASMER_LLVM_VERSION }} | |
| cache-save-if: ${{ env.HEAVY_CACHE_SAVE_IF }} | |
| - name: Build and qualify portable WASIX postmaster inputs | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-moon-targets.sh --upstream deep liboliphaunt-wasix-postmaster:portable-inputs liboliphaunt-wasix-postmaster:runtime-patch-tests liboliphaunt-wasix-postmaster:regression | |
| - name: Upload portable WASIX postmaster build inputs | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: liboliphaunt-wasix-postmaster-portable-build-inputs | |
| path: target/oliphaunt-wasix-postmaster/portable-inputs/wasix-postmaster-portable-build-inputs.tar.gz | |
| if-no-files-found: error | |
| - name: Upload Postmaster failure diagnostics | |
| if: ${{ failure() }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: wasix-postmaster-portable-diagnostics | |
| path: | | |
| target/oliphaunt-wasix-postmaster/reports | |
| target/oliphaunt-wasix-postmaster/runtime/reports | |
| retention-days: 3 | |
| wasix-postmaster-target: | |
| name: Builds / WASIX Postmaster / ${{ matrix.target_id }} + qualification | |
| needs: | |
| - affected | |
| - wasix-postmaster-portable | |
| if: ${{ !cancelled() && !failure() && needs.affected.result == 'success' && needs.wasix-postmaster-portable.result == 'success' && contains(fromJson(needs.affected.outputs.jobs), 'wasix-postmaster') }} | |
| runs-on: ${{ matrix.os }} | |
| timeout-minutes: 360 | |
| strategy: | |
| fail-fast: false | |
| matrix: ${{ fromJson(needs.affected.outputs.liboliphaunt_wasix_postmaster_runtime_matrix || '{"include":[]}') }} | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| - name: Set up Rust | |
| uses: ./.github/actions/setup-rust | |
| - name: Install portable shell utilities | |
| if: ${{ runner.os == 'macOS' }} | |
| run: | | |
| brew install bash coreutils findutils util-linux | |
| { | |
| echo "$(brew --prefix bash)/bin" | |
| echo "$(brew --prefix coreutils)/libexec/gnubin" | |
| echo "$(brew --prefix findutils)/libexec/gnubin" | |
| echo "$(brew --prefix util-linux)/bin" | |
| } >> "$GITHUB_PATH" | |
| - name: Install Wasmer LLVM 22.1 | |
| uses: ./.github/actions/setup-wasmer-llvm | |
| with: | |
| url: ${{ matrix.llvm_url }} | |
| sha256: ${{ matrix.llvm_sha256 }} | |
| bytes: ${{ matrix.llvm_bytes }} | |
| version: ${{ env.WASMER_LLVM_VERSION }} | |
| - name: Download portable WASIX postmaster build inputs | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-wasix-postmaster-portable-build-inputs | |
| path: target/oliphaunt-wasix-postmaster/portable-input-download | |
| - name: Restore portable WASIX postmaster build inputs | |
| run: | | |
| archive=target/oliphaunt-wasix-postmaster/portable-input-download/wasix-postmaster-portable-build-inputs.tar.gz | |
| test -f "$archive" | |
| tar -xzf "$archive" --strip-components=1 \ | |
| -C target/oliphaunt-wasix-postmaster | |
| - name: Build, qualify, and package target WASIX postmaster | |
| env: | |
| OLIPHAUNT_WASIX_POSTMASTER_PORTABLE_INPUTS: "1" | |
| WASIX_INSTALL_DIR: ${{ github.workspace }}/target/oliphaunt-wasix-postmaster/install/wasix-core-release-o3 | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-moon-targets.sh --upstream deep liboliphaunt-wasix-postmaster:release-assets liboliphaunt-wasix-postmaster:immediate-recovery liboliphaunt-wasix-postmaster:linear-memory-integration | |
| - name: Upload target WASIX postmaster release asset | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: liboliphaunt-wasix-postmaster-release-assets-${{ matrix.target_id }} | |
| path: ${{ matrix.release_asset_path }} | |
| if-no-files-found: error | |
| wasix-postmaster: | |
| name: Builds / WASIX Postmaster / Aggregate release assets | |
| needs: | |
| - affected | |
| - wasix-postmaster-target | |
| if: ${{ !cancelled() && !failure() && needs.affected.result == 'success' && needs.wasix-postmaster-target.result == 'success' && contains(fromJson(needs.affected.outputs.jobs), 'wasix-postmaster') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 15 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| - name: Download target WASIX postmaster release assets | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| pattern: liboliphaunt-wasix-postmaster-release-assets-* | |
| path: target/oliphaunt-wasix-postmaster/release-assets | |
| merge-multiple: true | |
| - name: Merge target WASIX postmaster release assets | |
| env: | |
| OLIPHAUNT_CI_JOB_TARGETS_JSON: '{"wasix-postmaster-aggregate":["liboliphaunt-wasix-postmaster:finalize-release-assets"]}' | |
| OLIPHAUNT_MOON_TRANSFERRED_DEPS_JSON: '["liboliphaunt-wasix-postmaster:release-assets"]' | |
| run: .github/scripts/run-planned-moon-job.sh wasix-postmaster-aggregate | |
| - name: Upload complete WASIX postmaster release assets | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: liboliphaunt-wasix-postmaster-release-assets | |
| path: target/oliphaunt-wasix-postmaster/release-assets | |
| if-no-files-found: error | |
| native-extension-lifecycle: | |
| name: E2E / Native Extension Lifecycle / ${{ matrix.label }} | |
| needs: | |
| - affected | |
| - extension-artifacts-native-linux | |
| - liboliphaunt-native-desktop-linux | |
| - broker-runtime-linux | |
| - rust-sdk-package | |
| if: ${{ !cancelled() && !failure() && needs.affected.result == 'success' && needs.extension-artifacts-native-linux.result == 'success' && needs.liboliphaunt-native-desktop-linux.result == 'success' && needs.broker-runtime-linux.result == 'success' && needs.rust-sdk-package.result == 'success' && contains(fromJson(needs.affected.outputs.jobs), 'native-extension-lifecycle') }} | |
| strategy: | |
| fail-fast: false | |
| matrix: ${{ fromJson(needs.affected.outputs.native_extension_lifecycle_matrix) }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 120 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 1 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| with: | |
| install-workspace: "false" | |
| - name: Set up Deno for packed native tools smoke | |
| if: ${{ matrix.shard == 0 }} | |
| uses: ./.github/actions/setup-deno | |
| with: | |
| deno-version: ${{ env.DENO_VERSION }} | |
| - name: Download same-run Linux native runtime | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-native-release-assets-linux-x64-gnu | |
| path: target/native-extension-lifecycle/input/runtime | |
| - name: Download same-run Linux exact-extension artifacts | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-native-extension-artifacts-linux-x64-gnu | |
| path: target/native-extension-lifecycle/input/extensions | |
| - name: Download same-run Linux broker | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: oliphaunt-broker-release-assets-linux-x64-gnu | |
| path: target/native-extension-lifecycle/input/broker | |
| - name: Download same-run native lifecycle proof runner | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: oliphaunt-native-extension-proof-linux-x64-gnu | |
| path: target/native-extension-lifecycle/input/proof-runner | |
| - name: Run packed Rust release consumer | |
| if: ${{ matrix.shard == 0 }} | |
| run: | | |
| chmod 0755 \ | |
| target/native-extension-lifecycle/input/proof-runner/oliphaunt-rust-release-consumer | |
| sdks/rust/sdk/tools/check-release-consumer.sh run \ | |
| target/native-extension-lifecycle/input/proof-runner/oliphaunt-rust-release-consumer \ | |
| target/native-extension-lifecycle/input/runtime | |
| - name: Run planned native extension lifecycle proof | |
| id: native_extension_lifecycle | |
| env: | |
| CI_HEAD_SHA: ${{ github.event.pull_request.head.sha || github.sha }} | |
| OLIPHAUNT_NATIVE_EXTENSION_PROOF_SQL_NAMES: ${{ needs.affected.outputs.native_extension_lifecycle_sql_names_csv }} | |
| SHARD_INDEX: ${{ matrix.shard }} | |
| SHARD_COUNT: ${{ matrix.shard_count }} | |
| run: | | |
| mkdir -p target/native-extension-lifecycle/evidence | |
| extensions/tests/native/tools/run-native-extension-lifecycle-proof.sh 2>&1 \ | |
| | tee "target/native-extension-lifecycle/evidence/job-shard-${SHARD_INDEX}.log" | |
| - name: Upload native extension lifecycle evidence | |
| id: native_extension_lifecycle_evidence | |
| if: ${{ always() && steps.native_extension_lifecycle.outcome != 'skipped' }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: native-extension-lifecycle-evidence-${{ matrix.shard }} | |
| path: target/native-extension-lifecycle/evidence | |
| if-no-files-found: error | |
| retention-days: 30 | |
| native-extension-lifecycle-aggregate: | |
| name: E2E / Native Extension Lifecycle Evidence | |
| needs: | |
| - affected | |
| - native-extension-lifecycle | |
| if: ${{ !cancelled() && !failure() && needs.affected.result == 'success' && needs.native-extension-lifecycle.result == 'success' && contains(fromJson(needs.affected.outputs.jobs), 'native-extension-lifecycle') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 10 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 1 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| with: | |
| install-workspace: "false" | |
| - name: Download all same-run native lifecycle shard receipts | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| pattern: native-extension-lifecycle-evidence-* | |
| path: target/native-extension-lifecycle/aggregate/input | |
| merge-multiple: false | |
| - name: Verify exact aggregate native extension lifecycle proof | |
| id: native_extension_lifecycle_aggregate | |
| env: | |
| CI_HEAD_SHA: ${{ github.event.pull_request.head.sha || github.sha }} | |
| OLIPHAUNT_NATIVE_EXTENSION_PROOF_SQL_NAMES: ${{ needs.affected.outputs.native_extension_lifecycle_sql_names_csv }} | |
| OLIPHAUNT_NATIVE_EXTENSION_PROOF_SHARD_COUNT: ${{ needs.affected.outputs.native_extension_lifecycle_shard_count }} | |
| run: | | |
| actual_sha="$(git rev-parse HEAD)" | |
| if [[ "$actual_sha" != "$CI_HEAD_SHA" ]]; then | |
| echo "native lifecycle aggregate candidate mismatch: expected $CI_HEAD_SHA, got $actual_sha" >&2 | |
| exit 1 | |
| fi | |
| candidate_tree="$(git rev-parse 'HEAD^{tree}')" | |
| mkdir -p target/native-extension-lifecycle/aggregate/output | |
| tools/dev/bun.sh extensions/tests/native/tools/verify-native-extension-lifecycle-receipts.mts \ | |
| --receipts target/native-extension-lifecycle/aggregate/input \ | |
| --candidate-sha "$CI_HEAD_SHA" \ | |
| --candidate-tree "$candidate_tree" \ | |
| --expected-extensions-csv "$OLIPHAUNT_NATIVE_EXTENSION_PROOF_SQL_NAMES" \ | |
| --expected-shard-count "$OLIPHAUNT_NATIVE_EXTENSION_PROOF_SHARD_COUNT" \ | |
| --output target/native-extension-lifecycle/aggregate/output/aggregate-receipt.json | |
| - name: Upload aggregate native extension lifecycle evidence | |
| id: native_extension_lifecycle_aggregate_evidence | |
| if: ${{ always() && steps.native_extension_lifecycle_aggregate.outcome != 'skipped' }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: native-extension-lifecycle-evidence | |
| path: target/native-extension-lifecycle/aggregate | |
| if-no-files-found: error | |
| retention-days: 30 | |
| wasix-release-regression: | |
| name: E2E / WASIX Release Regression | |
| needs: | |
| - affected | |
| - extension-artifacts-wasix | |
| - liboliphaunt-wasix-runtime | |
| - liboliphaunt-wasix-aot | |
| if: ${{ !cancelled() && !failure() && needs.affected.result == 'success' && needs.extension-artifacts-wasix.result == 'success' && needs.liboliphaunt-wasix-runtime.result == 'success' && needs.liboliphaunt-wasix-aot.result == 'success' && needs.affected.outputs.wasix_release_regression_required == 'true' }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 240 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 1 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| with: | |
| install-workspace: "true" | |
| - name: Set up Rust | |
| uses: ./.github/actions/setup-rust | |
| with: | |
| components: rustfmt | |
| - name: Download same-run portable WASIX outputs | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-wasix-runtime-portable | |
| path: . | |
| - name: Download same-run WASIX exact-extension outputs | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| pattern: liboliphaunt-wasix-extension-artifacts-* | |
| path: target/extensions/wasix/release-assets | |
| merge-multiple: true | |
| - name: Download same-run Linux extension AOT outputs | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-wasix-extension-aot-linux-x64-gnu | |
| path: target/extensions/wasix/aot-artifacts | |
| - name: Download same-run portable WASIX tools compiler outputs | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: postgres-tools-wasix-compiler-output | |
| path: target/postgres-tools/wasix/assets | |
| - name: Download same-run Linux WASIX tools AOT outputs | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: postgres-tools-wasix-aot-linux-x64-gnu | |
| path: target/postgres-tools/wasix/aot | |
| - name: Download same-run Linux host AOT outputs | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-wasix-runtime-aot-linux-x64-gnu | |
| path: target/oliphaunt-wasix/host-aot-download | |
| - name: Restore Linux host AOT target layout | |
| run: | | |
| artifact_dir=target/oliphaunt-wasix/host-aot-download | |
| marker="$artifact_dir/target-triple.txt" | |
| raw_target_dir="$artifact_dir/files" | |
| if [[ ! -f "$marker" || ! -d "$raw_target_dir" ]]; then | |
| echo "invalid Linux host AOT artifact envelope in $artifact_dir" >&2 | |
| exit 1 | |
| fi | |
| target="$(tr -d '\r\n' < "$marker")" | |
| if [[ "$target" != x86_64-unknown-linux-gnu ]]; then | |
| echo "Linux host AOT artifact targets $target, expected x86_64-unknown-linux-gnu" >&2 | |
| exit 1 | |
| fi | |
| destination="target/oliphaunt-wasix/aot/$target" | |
| mkdir -p "$destination" | |
| rsync -a "$raw_target_dir/" "$destination/" | |
| - name: Stage exact-extension WASIX evidence inputs | |
| run: tools/dev/bun.sh extensions/artifacts/packages/tools/build-extension-ci-artifacts.mts --all --family wasix --require-wasix | |
| - name: Collect WASIX extension evidence | |
| id: regression | |
| env: | |
| CI_HEAD_SHA: ${{ github.event.pull_request.head.sha || github.sha }} | |
| OLIPHAUNT_WASIX_EXTENSION_ARTIFACT_ROOT: ${{ github.workspace }}/target/extension-artifacts | |
| run: | | |
| actual_sha="$(git rev-parse HEAD)" | |
| if [[ "$actual_sha" != "$CI_HEAD_SHA" ]]; then | |
| echo "checked-out candidate $actual_sha does not match requested SHA $CI_HEAD_SHA" >&2 | |
| exit 1 | |
| fi | |
| run_id="$(date -u +%Y-%m-%dT%H%M%SZ)-ci-${GITHUB_RUN_ID}-${GITHUB_RUN_ATTEMPT}-${CI_HEAD_SHA}" | |
| run_path="extensions/evidence/runs/$run_id.json" | |
| echo "run_path=$run_path" >> "$GITHUB_OUTPUT" | |
| mkdir -p target/qualification/wasix-release-regression | |
| extensions/tools/collect-wasix-evidence.sh "$run_id" 2>&1 \ | |
| | tee target/qualification/wasix-release-regression/runtime-smoke.log | |
| - name: Upload WASIX extension evidence | |
| if: ${{ steps.regression.outcome == 'success' }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: wasix-release-regression-evidence | |
| path: | | |
| ${{ steps.regression.outputs.run_path }} | |
| extensions/generated/docs/extension-evidence.json | |
| target/qualification/wasix-release-regression/runtime-smoke.log | |
| if-no-files-found: error | |
| overwrite: true | |
| retention-days: 90 | |
| - name: Upload WASIX regression diagnostics | |
| if: ${{ always() && steps.regression.outcome != 'success' }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: wasix-release-regression-diagnostics | |
| path: target/qualification/wasix-release-regression/runtime-smoke.log | |
| if-no-files-found: ignore | |
| overwrite: true | |
| retention-days: 14 | |
| mobile-build-android: | |
| name: Builds / Android App (${{ matrix.target }}) | |
| needs: | |
| - affected | |
| - js-sdk-package | |
| - mobile-extension-packages-android | |
| - liboliphaunt-native-android | |
| - liboliphaunt-native-android-abi | |
| - kotlin-sdk-package | |
| - react-native-sdk-package | |
| if: ${{ !cancelled() && !failure() && needs.affected.result == 'success' && needs.js-sdk-package.result == 'success' && needs.mobile-extension-packages-android.result == 'success' && needs.liboliphaunt-native-android.result == 'success' && needs.liboliphaunt-native-android-abi.result == 'success' && needs.kotlin-sdk-package.result == 'success' && needs.react-native-sdk-package.result == 'success' && contains(fromJson(needs.affected.outputs.jobs), 'mobile-build-android') }} | |
| strategy: | |
| fail-fast: false | |
| matrix: ${{ fromJson(needs.affected.outputs.react_native_android_mobile_app_matrix) }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 180 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| with: | |
| install-workspace: "true" | |
| - name: Set up Android | |
| uses: ./.github/actions/setup-android | |
| with: | |
| native-ccache: "true" | |
| - name: Set up Rust | |
| uses: ./.github/actions/setup-rust | |
| - name: Reclaim Android mobile build disk | |
| run: bash .github/scripts/reclaim-android-mobile-build-disk.sh | |
| - name: Download Android liboliphaunt target | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-native-target-${{ matrix.target }} | |
| path: . | |
| - name: Restore Android native build outputs | |
| run: | | |
| tar -xzf native-target.tar.gz | |
| rm native-target.tar.gz | |
| - name: Download canonical ICU data | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: database-resources-icu-data-portable | |
| path: target/database-resources/mobile-inputs | |
| - name: Download Android database seed | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: database-resources-native-seeds-android-datum64 | |
| path: target/database-resources/mobile-inputs | |
| - name: Stage selected Android ICU seed and data | |
| run: | | |
| shopt -s nullglob | |
| icu_archives=(target/database-resources/mobile-inputs/*-icu-data.tar.gz) | |
| seed_archives=(target/database-resources/mobile-inputs/*-seed-native-android-datum64-icu.tar.zst) | |
| if [ "${#icu_archives[@]}" -ne 1 ] || [ "${#seed_archives[@]}" -ne 1 ]; then | |
| echo 'Expected exactly one canonical ICU archive and one Android ICU seed.' >&2 | |
| exit 1 | |
| fi | |
| icu_root=target/database-resources/mobile-android/icu | |
| seed_root=target/database-resources/mobile-android/cluster-seed-icu | |
| mkdir -p "$icu_root" | |
| tar -xzf "${icu_archives[0]}" -C "$icu_root" | |
| tools/dev/bun.sh database-resources/seeds/package-mobile-carriers.mts stage \ | |
| --archive "${seed_archives[0]}" --manifest "${seed_archives[0]%.tar.zst}.json" \ | |
| --destination "$seed_root" --target android-datum64 --profile icu --icu-data "$icu_root/share/icu" | |
| echo "OLIPHAUNT_EXPO_ANDROID_SEED_DIR=$GITHUB_WORKSPACE/$seed_root" >> "$GITHUB_ENV" | |
| echo "OLIPHAUNT_EXPO_ANDROID_ICU_DATA_DIR=$GITHUB_WORKSPACE/$icu_root/share/icu" >> "$GITHUB_ENV" | |
| - name: Download Kotlin SDK package artifacts | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: oliphaunt-kotlin-sdk-package-artifacts | |
| path: target/sdk-artifacts/oliphaunt-kotlin | |
| - name: Download React Native SDK package artifacts | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: oliphaunt-react-native-sdk-package-artifacts | |
| path: target/sdk-artifacts/oliphaunt-react-native | |
| - name: Download exact-extension package artifacts | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: oliphaunt-mobile-extension-package-artifacts-android | |
| path: target/extension-artifacts | |
| - name: Build Android mobile app | |
| env: | |
| OLIPHAUNT_EXPO_ALLOW_NATIVE_BUILDS: "0" | |
| OLIPHAUNT_EXPO_REQUIRE_SDK_ARTIFACTS: "1" | |
| OLIPHAUNT_EXPO_SDK_ARTIFACT_ROOT: ${{ github.workspace }}/target/sdk-artifacts | |
| OLIPHAUNT_EXPO_ANDROID_ABI: ${{ matrix.abi }} | |
| OLIPHAUNT_EXPO_ANDROID_BUILD_TYPE: release | |
| OLIPHAUNT_EXPO_ANDROID_EXTENSIONS: ${{ needs.affected.outputs.extension_package_sql_names_csv }} | |
| OLIPHAUNT_EXPO_ANDROID_ICU: "1" | |
| OLIPHAUNT_EXPO_REQUIRE_PREBUILT_EXTENSIONS: "1" | |
| OLIPHAUNT_EXPO_EXTENSION_ARTIFACT_ROOT: ${{ github.workspace }}/target/extension-artifacts | |
| OLIPHAUNT_EXPO_ANDROID_OLIPHAUNT_SO: ${{ github.workspace }}/${{ matrix.build-root }}/out/liboliphaunt.so | |
| OLIPHAUNT_EXPO_ANDROID_RUNTIME_DIR: ${{ github.workspace }}/target/liboliphaunt-mobile-host/${{ matrix.target }}/install | |
| OLIPHAUNT_EXPO_ANDROID_INITDB: ${{ github.workspace }}/target/liboliphaunt-mobile-host/${{ matrix.target }}/install/bin/initdb | |
| OLIPHAUNT_MOON_TRANSFERRED_DEPS_JSON: '["database-resources:package-icu", "database-resources:build-native-android-icu", "extension-packages:package-mobile", "liboliphaunt-native:package-runtime-android-x86_64", "liboliphaunt-native:finalize-runtime-android-abi", "oliphaunt-kotlin:package", "oliphaunt-react-native:package"]' | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-planned-moon-job.sh mobile-build-android | |
| - name: Validate Android mobile app artifacts | |
| run: tools/dev/bun.sh sdks/react-native/tools/check-mobile-artifacts.mts android | |
| - name: Upload Android mobile build logs | |
| if: ${{ always() }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: react-native-mobile-android-build-logs-${{ matrix.target }} | |
| path: | | |
| target/mobile/react-native/android-build/logs | |
| target/oliphaunt-expo-android-*/logs | |
| if-no-files-found: ignore | |
| - name: Upload Android mobile app | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: react-native-mobile-android-app-${{ matrix.target }} | |
| path: target/mobile-build/react-native/android | |
| if-no-files-found: error | |
| mobile-build-ios: | |
| name: Builds / iOS App | |
| needs: | |
| - affected | |
| - js-sdk-package | |
| - mobile-extension-packages-ios | |
| - liboliphaunt-native-ios | |
| - liboliphaunt-native-ios-abi | |
| - react-native-sdk-package | |
| - swift-sdk-package | |
| if: ${{ contains(fromJson(needs.affected.outputs.jobs), 'mobile-build-ios') }} | |
| runs-on: macos-26 | |
| timeout-minutes: 180 | |
| env: | |
| OLIPHAUNT_EXTENSION_ARTIFACT_ROOT: ${{ github.workspace }}/target/mobile-extension-artifacts | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 0 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Moon | |
| uses: ./.github/actions/setup-moon | |
| with: | |
| install-workspace: "true" | |
| - name: Set up Apple | |
| uses: ./.github/actions/setup-apple | |
| - name: Set up Rust | |
| uses: ./.github/actions/setup-rust | |
| - name: Download iOS liboliphaunt target | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-native-target-ios-xcframework | |
| path: . | |
| - name: Restore iOS native build outputs | |
| run: | | |
| tar -xzf native-target.tar.gz | |
| rm native-target.tar.gz | |
| - name: Download ABI-compatible iOS liboliphaunt release assets | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: liboliphaunt-native-abi-compatible-release-assets-ios-datum64 | |
| path: target/liboliphaunt/release-assets | |
| - name: Download canonical ICU data | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: database-resources-icu-data-portable | |
| path: target/database-resources/mobile-inputs | |
| - name: Download iOS database seed | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: database-resources-native-seeds-ios-datum64 | |
| path: target/database-resources/mobile-inputs | |
| - name: Stage selected iOS ICU seed and data | |
| run: | | |
| shopt -s nullglob | |
| icu_archives=(target/database-resources/mobile-inputs/*-icu-data.tar.gz) | |
| seed_archives=(target/database-resources/mobile-inputs/*-seed-native-ios-datum64-icu.tar.zst) | |
| if [ "${#icu_archives[@]}" -ne 1 ] || [ "${#seed_archives[@]}" -ne 1 ]; then | |
| echo 'Expected exactly one canonical ICU archive and one iOS ICU seed.' >&2 | |
| exit 1 | |
| fi | |
| database-resources/icu/tools/check-icu-npm-cocoapods-consumer.sh "${icu_archives[0]}" | |
| icu_root=target/database-resources/mobile-ios/icu | |
| seed_root=target/database-resources/mobile-ios/cluster-seed-icu | |
| mkdir -p "$icu_root" | |
| tar -xzf "${icu_archives[0]}" -C "$icu_root" | |
| tools/dev/bun.sh database-resources/seeds/package-mobile-carriers.mts stage \ | |
| --archive "${seed_archives[0]}" --manifest "${seed_archives[0]%.tar.zst}.json" \ | |
| --destination "$seed_root" --target ios-datum64 --profile icu --icu-data "$icu_root/share/icu" | |
| { | |
| echo "OLIPHAUNT_EXPO_IOS_SEED_DIR=$GITHUB_WORKSPACE/$seed_root" | |
| echo "OLIPHAUNT_EXPO_IOS_ICU_DATA_DIR=$GITHUB_WORKSPACE/$icu_root/share/icu" | |
| echo "OLIPHAUNT_IOS_ICU_DATA_DIR=$GITHUB_WORKSPACE/$icu_root/share/icu" | |
| } >> "$GITHUB_ENV" | |
| - name: Download Swift SDK package artifacts | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: oliphaunt-swift-sdk-package-artifacts | |
| path: target/sdk-artifacts/oliphaunt-swift | |
| - name: Download React Native SDK package artifacts | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: oliphaunt-react-native-sdk-package-artifacts | |
| path: target/sdk-artifacts/oliphaunt-react-native | |
| - name: Download exact-extension package artifacts | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: oliphaunt-mobile-extension-package-artifacts-ios | |
| path: target/mobile-extension-artifacts | |
| - name: Render exact-SHA cache-warm iOS carrier manifest | |
| run: | | |
| tools/dev/bun.sh sdks/swift/tools/ios-carrier-manifest.mts \ | |
| --base-asset-dir target/liboliphaunt/release-assets \ | |
| --extension-root target/mobile-extension-artifacts \ | |
| --output target/release/ios-carriers/oliphaunt-react-native-ios-carriers.json \ | |
| --local-urls | |
| - name: Qualify every exact iOS carrier | |
| env: | |
| IOS_CARRIER_MANIFEST: target/release/ios-carriers/oliphaunt-react-native-ios-carriers.json | |
| IOS_CARRIER_STAGE: target/qualification/react-native-ios-all-carriers | |
| IOS_CARRIER_CACHE: target/qualification/react-native-ios-carrier-cache | |
| PLANNED_EXTENSION_SQL_NAMES: ${{ needs.affected.outputs.extension_package_sql_names_csv }} | |
| run: | | |
| bash sdks/react-native/tools/qualify-ios-carriers.sh | |
| - name: Run exact-extension Swift release consumer | |
| env: | |
| CI_HEAD_SHA: ${{ github.event.pull_request.head.sha || github.sha }} | |
| OLIPHAUNT_SWIFT_NATIVE_ASSET_DIR: ${{ github.workspace }}/target/liboliphaunt/release-assets | |
| OLIPHAUNT_SWIFT_SDK_ARTIFACT_DIR: ${{ github.workspace }}/target/sdk-artifacts/oliphaunt-swift | |
| PLANNED_EXTENSION_PRODUCTS: ${{ needs.affected.outputs.extension_package_products_csv }} | |
| run: | | |
| source_carrier=target/sdk-artifacts/oliphaunt-swift/release-tree/sdks/swift/Carriers/oliphaunt-react-native-ios-carriers.json | |
| react_native_source_carrier=target/sdk-artifacts/oliphaunt-react-native/ios-carriers/oliphaunt-react-native-ios-carriers.json | |
| cache_warm_carrier=target/release/ios-carriers/oliphaunt-react-native-ios-carriers.json | |
| if ! cmp -s "$source_carrier" "$react_native_source_carrier"; then | |
| echo 'Swift and React Native package artifacts disagree on the selection-neutral source carrier.' >&2 | |
| diff -u "$source_carrier" "$react_native_source_carrier" || true | |
| exit 1 | |
| fi | |
| consumer_args=( | |
| --source-carrier "$source_carrier" | |
| --cache-warm-carrier "$cache_warm_carrier" | |
| ) | |
| evidence_dir=target/release/ios-carriers/qualification/swift-independent-carriers | |
| mkdir -p "$evidence_dir" | |
| cp "$source_carrier" "$evidence_dir/selection-neutral-source-carrier.json" | |
| cp "$react_native_source_carrier" "$evidence_dir/react-native-selection-neutral-source-carrier.json" | |
| product_count=0 | |
| while IFS= read -r product; do | |
| [[ -n "$product" ]] || continue | |
| if [[ ! "$product" =~ ^oliphaunt-extension-[A-Za-z0-9._-]+$ ]]; then | |
| echo "Planner returned an invalid exact-extension product id: $product" >&2 | |
| exit 1 | |
| fi | |
| product_root="$(tools/dev/bun.sh tools/release/query.mts \ | |
| extension-artifact-root --product "$product" --family native)" | |
| product_root="$OLIPHAUNT_EXTENSION_ARTIFACT_ROOT/${product_root#target/extension-artifacts/}" | |
| release_assets="$product_root/release-assets" | |
| product_carriers=() | |
| while IFS= read -r carrier; do | |
| product_carriers+=("$carrier") | |
| done < <(find "$release_assets" -maxdepth 1 -type f -name '*-swift-extension-carrier.json' | LC_ALL=C sort) | |
| if (( ${#product_carriers[@]} != 1 )); then | |
| echo "Planner-selected $product must provide exactly one independent Swift carrier; found ${#product_carriers[@]}" >&2 | |
| exit 1 | |
| fi | |
| consumer_args+=(--extension-carrier "${product_carriers[0]}") | |
| cp "${product_carriers[0]}" "$evidence_dir/$(basename "${product_carriers[0]}")" | |
| product_count=$((product_count + 1)) | |
| done < <(printf '%s' "$PLANNED_EXTENSION_PRODUCTS" | tr ',' '\n') | |
| if (( product_count == 0 )); then | |
| echo 'Exact-extension Swift release qualification resolved no independent extension carriers.' >&2 | |
| exit 1 | |
| fi | |
| printf '%s\n' "${consumer_args[@]}" > "$evidence_dir/consumer-arguments.txt" | |
| sdks/swift/tools/check-extension-release-consumer.sh "${consumer_args[@]}" | |
| - name: Build iOS mobile app | |
| env: | |
| OLIPHAUNT_EXPO_ALLOW_NATIVE_BUILDS: "0" | |
| OLIPHAUNT_EXPO_EXTENSION_ARTIFACT_ROOT: ${{ env.OLIPHAUNT_EXTENSION_ARTIFACT_ROOT }} | |
| OLIPHAUNT_EXPO_REQUIRE_SDK_ARTIFACTS: "1" | |
| OLIPHAUNT_EXPO_SDK_ARTIFACT_ROOT: ${{ github.workspace }}/target/sdk-artifacts | |
| OLIPHAUNT_EXPO_IOS_CONFIGURATION: Release | |
| OLIPHAUNT_EXPO_IOS_ICU: "1" | |
| OLIPHAUNT_EXPO_IOS_EXTENSIONS: ${{ needs.affected.outputs.extension_package_sql_names_csv }} | |
| OLIPHAUNT_EXPO_IOS_SDK: iphonesimulator | |
| OLIPHAUNT_EXPO_REQUIRE_PREBUILT_EXTENSIONS: "1" | |
| OLIPHAUNT_EXPO_IOS_OLIPHAUNT_XCFRAMEWORK: ${{ github.workspace }}/target/liboliphaunt-ios-xcframework/out/liboliphaunt.xcframework | |
| OLIPHAUNT_EXPO_IOS_RUNTIME_DIR: ${{ github.workspace }}/target/liboliphaunt-mobile-host/ios-xcframework/install | |
| OLIPHAUNT_EXPO_IOS_INITDB: ${{ github.workspace }}/target/liboliphaunt-mobile-host/ios-xcframework/install/bin/initdb | |
| OLIPHAUNT_REACT_NATIVE_IOS_BASE_CARRIER: ${{ github.workspace }}/target/release/ios-carriers/oliphaunt-react-native-ios-carriers.json | |
| OLIPHAUNT_MOON_TRANSFERRED_DEPS_JSON: '["database-resources:package-icu", "database-resources:build-native-ios-icu", "extension-packages:package-mobile", "liboliphaunt-native:package-runtime-ios-xcframework", "oliphaunt-react-native:package", "oliphaunt-swift:package"]' | |
| run: OLIPHAUNT_CI_JOB_TARGETS_JSON='${{ needs.affected.outputs.job_targets }}' .github/scripts/run-planned-moon-job.sh mobile-build-ios | |
| - name: Validate iOS mobile app artifacts | |
| run: tools/dev/bun.sh sdks/react-native/tools/check-mobile-artifacts.mts ios | |
| - name: Pack fidelity-preserving iOS app transport | |
| run: | | |
| bash sdks/react-native/tools/ios-app-transport.sh pack \ | |
| --app-dir target/mobile-build/react-native/ios \ | |
| --transport-dir target/mobile-build/react-native/ios-transport | |
| - name: Upload iOS mobile build logs | |
| if: ${{ always() }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: react-native-mobile-ios-build-logs | |
| path: | | |
| target/mobile/react-native/ios-build/logs | |
| target/mobile/react-native/ios-build/xcodebuild.log | |
| target/oliphaunt-expo-ios-*/logs | |
| target/oliphaunt-expo-ios-*/xcodebuild.log | |
| if-no-files-found: ignore | |
| - name: Upload iOS mobile app | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: react-native-mobile-ios-app | |
| path: target/mobile-build/react-native/ios-transport | |
| if-no-files-found: error | |
| - name: Upload exact-SHA iOS carrier evidence | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: oliphaunt-react-native-ios-carriers | |
| path: target/release/ios-carriers | |
| if-no-files-found: error | |
| overwrite: true | |
| builds: | |
| name: Builds | |
| if: ${{ !cancelled() && (github.event_name != 'pull_request' || github.event.action != 'closed') }} | |
| needs: | |
| - affected | |
| - extension-artifacts-native | |
| - extension-artifacts-wasix | |
| - extension-packages | |
| - mobile-extension-packages | |
| - liboliphaunt-native-android | |
| - liboliphaunt-native-desktop | |
| - liboliphaunt-native-ios | |
| - liboliphaunt-native-release-assets | |
| - rust-sdk-package | |
| - broker-runtime | |
| - broker-release-assets | |
| - node-direct | |
| - node-direct-release-assets | |
| - wasix-napi | |
| - wasix-napi-release-assets | |
| - swift-bindings | |
| - swift-sdk-package | |
| - kotlin-sdk-package | |
| - kotlin-maven-staging | |
| - react-native-sdk-package | |
| - js-sdk-package | |
| - wasix-ts-sdk-package | |
| - native-consumers | |
| - wasix-rust-package | |
| - liboliphaunt-wasix-runtime | |
| - liboliphaunt-wasix-aot | |
| - liboliphaunt-wasix-release-assets | |
| - wasix-postmaster | |
| - wasix-release-regression | |
| - mobile-build-android | |
| - mobile-build-ios | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 15 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 1 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Bun | |
| uses: ./.github/actions/setup-bun | |
| - name: Check selected build jobs | |
| id: selected_builds_gate | |
| env: | |
| NEEDS_JSON: ${{ toJson(needs) }} | |
| SELECTED_JOBS_JSON: ${{ needs.affected.outputs.builder_jobs }} | |
| GATE_LABEL: selected build jobs | |
| run: bun .github/scripts/check-ci-gate.mts selected | |
| - name: Check WASIX release regression | |
| id: wasix_regression_gate | |
| env: | |
| NEEDS_JSON: ${{ toJson(needs) }} | |
| SELECTED_JOBS_JSON: ${{ needs.affected.outputs.wasix_release_regression_required == 'true' && '["wasix-release-regression"]' || '[]' }} | |
| GATE_LABEL: WASIX release regression | |
| run: bun .github/scripts/check-ci-gate.mts selected | |
| mobile-e2e-android: | |
| name: E2E / Android App | |
| needs: | |
| - affected | |
| - mobile-build-android | |
| if: ${{ !cancelled() && !failure() && needs.affected.result == 'success' && needs.mobile-build-android.result == 'success' && contains(fromJson(needs.affected.outputs.jobs), 'mobile-build-android') }} | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 45 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 1 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Node | |
| id: setup_android_e2e_node | |
| uses: ./.github/actions/setup-node-runtime | |
| - name: Reclaim Android emulator disk | |
| id: reclaim_android_emulator_disk | |
| run: bash .github/scripts/reclaim-android-mobile-build-disk.sh | |
| - name: Set up Android | |
| id: setup_android_e2e | |
| uses: ./.github/actions/setup-android | |
| with: | |
| gradle-cache: "false" | |
| - name: Set up Maestro | |
| uses: ./.github/actions/setup-maestro | |
| - name: Download Android app artifact | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: react-native-mobile-android-app-android-x86_64 | |
| path: target/mobile-build/react-native/android | |
| - name: List Android app artifact | |
| run: find target/mobile-build/react-native/android -maxdepth 2 -type f -print | |
| - name: Provision runner KVM access | |
| run: | | |
| test -c /dev/kvm | |
| if [ ! -r /dev/kvm ] || [ ! -w /dev/kvm ]; then | |
| sudo chmod a+rw /dev/kvm | |
| fi | |
| - name: Start Android emulator | |
| id: start_android_emulator | |
| env: | |
| OLIPHAUNT_ANDROID_EMULATOR_API: "35" | |
| OLIPHAUNT_ANDROID_EMULATOR_DISK_HEADROOM_MB: "2048" | |
| OLIPHAUNT_ANDROID_EMULATOR_PARTITION_SIZE_MB: "6144" | |
| run: tools/ci/start-android-emulator-ci.sh | |
| - name: Run Android installed-app E2E | |
| env: | |
| CI_HEAD_SHA: ${{ github.event.pull_request.head.sha || github.sha }} | |
| OLIPHAUNT_EXPO_ANDROID_BUILD_ARTIFACT_DIR: ${{ github.workspace }}/target/mobile-build/react-native/android | |
| OLIPHAUNT_EXPO_ANDROID_BUILD_TYPE: release | |
| OLIPHAUNT_EXPO_ANDROID_LIFECYCLE_SMOKE: "0" | |
| OLIPHAUNT_MOBILE_E2E_ASSERTION_RUNNER: maestro | |
| run: bash sdks/react-native/tools/mobile-e2e.sh android | |
| - name: Upload Android E2E reports | |
| if: ${{ always() }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: react-native-mobile-android-e2e-reports | |
| path: | | |
| target/mobile/react-native/android-e2e/reports | |
| target/mobile/react-native/android-e2e/logs | |
| ${{ runner.temp }}/oliphaunt-android-emulator.log | |
| if-no-files-found: ignore | |
| mobile-e2e-ios: | |
| name: E2E / iOS App | |
| needs: | |
| - affected | |
| - mobile-build-ios | |
| if: ${{ contains(fromJson(needs.affected.outputs.jobs), 'mobile-build-ios') }} | |
| runs-on: macos-26 | |
| timeout-minutes: 45 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 1 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Node and Bun | |
| uses: ./.github/actions/setup-node-bun | |
| - name: Set up Apple | |
| uses: ./.github/actions/setup-apple | |
| - name: Set up Maestro | |
| uses: ./.github/actions/setup-maestro | |
| - name: Download iOS app artifact | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: react-native-mobile-ios-app | |
| path: target/mobile-build/react-native/ios-transport | |
| - name: Verify and extract iOS app artifact | |
| id: ios_app_transport_verify | |
| run: | | |
| rm -rf target/mobile-build/react-native/ios | |
| bash sdks/react-native/tools/ios-app-transport.sh verify-extract \ | |
| --transport-dir target/mobile-build/react-native/ios-transport \ | |
| --output-dir target/mobile-build/react-native/ios | |
| - name: List iOS app artifact | |
| run: find target/mobile-build/react-native/ios -maxdepth 2 -print | |
| - name: Run iOS installed-app E2E | |
| env: | |
| CI_HEAD_SHA: ${{ github.event.pull_request.head.sha || github.sha }} | |
| OLIPHAUNT_EXPO_IOS_BUILD_ARTIFACT_DIR: ${{ github.workspace }}/target/mobile-build/react-native/ios | |
| OLIPHAUNT_EXPO_IOS_CONFIGURATION: Release | |
| OLIPHAUNT_EXPO_IOS_SDK: iphonesimulator | |
| OLIPHAUNT_EXPO_IOS_LIFECYCLE_SMOKE: "0" | |
| OLIPHAUNT_MOBILE_E2E_ASSERTION_RUNNER: maestro | |
| MAESTRO_DRIVER_STARTUP_TIMEOUT: "300000" | |
| run: bash sdks/react-native/tools/mobile-e2e.sh ios | |
| - name: Upload iOS E2E reports | |
| if: ${{ always() }} | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: react-native-mobile-ios-e2e-reports | |
| path: | | |
| target/mobile/react-native/ios-e2e/reports | |
| target/mobile/react-native/ios-e2e/logs | |
| target/mobile/react-native/ios-e2e/*.log | |
| if-no-files-found: ignore | |
| e2e: | |
| name: E2E | |
| if: ${{ !cancelled() && (github.event_name != 'pull_request' || github.event.action != 'closed') }} | |
| needs: | |
| - affected | |
| - native-extension-lifecycle-aggregate | |
| - mobile-e2e-android | |
| - mobile-e2e-ios | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 5 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 1 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Bun | |
| uses: ./.github/actions/setup-bun | |
| - name: Check final release execution qualification | |
| id: selected_e2e_gate | |
| env: | |
| NEEDS_JSON: ${{ toJson(needs) }} | |
| SELECTED_JOBS_JSON: ${{ needs.affected.outputs.e2e_jobs }} | |
| GATE_LABEL: final release execution qualification | |
| run: bun .github/scripts/check-ci-gate.mts selected | |
| required: | |
| name: Required | |
| if: ${{ !cancelled() && (github.event_name != 'pull_request' || github.event.action != 'closed') }} | |
| needs: | |
| - affected | |
| - release-intent | |
| - checks | |
| - tests | |
| - builds | |
| - e2e | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 5 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 1 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Bun | |
| uses: ./.github/actions/setup-bun | |
| - name: Check required jobs | |
| id: required_gate | |
| env: | |
| NEEDS_JSON: ${{ toJson(needs) }} | |
| REQUIRED_JOBS_JSON: '["affected","release-intent","checks","tests","builds","e2e"]' | |
| GATE_LABEL: required CI phases | |
| run: bun .github/scripts/check-ci-gate.mts required | |
| qualified: | |
| name: Qualified | |
| if: ${{ !cancelled() && (github.event_name == 'workflow_dispatch' || (github.event_name == 'push' && github.ref == 'refs/heads/main' && needs.affected.outputs.qualification_mode == 'selected-products')) }} | |
| needs: | |
| - affected | |
| - required | |
| - js-sdk-package | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 5 | |
| steps: | |
| - name: Require qualified CI success | |
| id: require_full_ci | |
| env: | |
| CI_EVENT_NAME: ${{ github.event_name }} | |
| CI_MOBILE_TARGET: ${{ inputs.mobile_target }} | |
| CI_NATIVE_TARGET: ${{ inputs.native_target }} | |
| CI_WASM_TARGET: ${{ inputs.wasm_target }} | |
| run: | | |
| if [[ '${{ needs.affected.result }}' != success || '${{ needs.required.result }}' != success ]]; then | |
| echo 'release qualification requires successful Plan and Required jobs' >&2 | |
| exit 1 | |
| fi | |
| if [[ "$CI_EVENT_NAME" == workflow_dispatch ]] && \ | |
| [[ "$CI_WASM_TARGET" != all || "$CI_NATIVE_TARGET" != all || "$CI_MOBILE_TARGET" != all ]]; then | |
| echo 'focused workflow_dispatch runs are diagnostic only and cannot qualify a release candidate' >&2 | |
| exit 1 | |
| fi | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | |
| with: | |
| fetch-depth: 1 | |
| ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
| persist-credentials: false | |
| - name: Set up Node.js | |
| uses: ./.github/actions/setup-node-runtime | |
| - name: Download same-run affected plan | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: artifact-build-plan | |
| path: target/qualification/affected-plan | |
| - name: Download required same-run WASIX evidence | |
| if: ${{ needs.affected.outputs.wasix_release_regression_required == 'true' }} | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c | |
| with: | |
| name: wasix-release-regression-evidence | |
| path: target/qualification/wasix-release-regression-evidence | |
| - name: Write exact-SHA qualification record | |
| id: qualification_record | |
| env: | |
| CI_HEAD_SHA: ${{ github.event.pull_request.head.sha || github.sha }} | |
| CI_QUALIFICATION_MODE: ${{ needs.affected.outputs.qualification_mode }} | |
| CI_PLAN_PATH: target/qualification/affected-plan/ci-plan.json | |
| WASIX_RELEASE_REGRESSION_REQUIRED: ${{ needs.affected.outputs.wasix_release_regression_required }} | |
| WASIX_EVIDENCE_ROOT: target/qualification/wasix-release-regression-evidence | |
| PRODUCER_RECEIPTS_JSON: ${{ format('[{0}]', needs.js-sdk-package.outputs.producer_receipt || '') }} | |
| run: bash .github/scripts/release-candidate.sh write | |
| - name: Upload exact-SHA qualification record | |
| id: qualification_evidence | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| with: | |
| name: oliphaunt-release-candidate | |
| path: target/qualification/oliphaunt-release-candidate.json | |
| if-no-files-found: error | |
| overwrite: true | |
| retention-days: 90 |