forked from prisma/prisma-engines
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
query-engine-c-abi: CI build for RN binaries (prisma#4838)
* query-engine-c-abi: CI build for RN binaries Adds GH Actions pipeline for building iOS & Andorid query engine for `prisma-react-native`. Pipeline is triggered by engineer, similar to Windows and Mac builds. See https://github.com/prisma/engineer/pull/120 Example of succesfull run: https://buildkite.com/prisma/release-prisma-engines/builds/3721#018f1a4f-95c9-4cdd-b551-94e53d4e1978 Contributes to prisma/team-orm#1106 * Update engineer * Run on ios 14
- Loading branch information
Serhii Tatarintsev
authored
Apr 29, 2024
1 parent
744b41c
commit 264f24c
Showing
8 changed files
with
128 additions
and
63 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,101 @@ | ||
name: Build Engines for React native | ||
on: | ||
workflow_dispatch: | ||
inputs: | ||
commit: | ||
description: "Commit on the given branch to build" | ||
required: false | ||
|
||
jobs: | ||
build-ios: | ||
# Do not change `name`, prisma-engines Buildkite build job depends on this name ending with the commit | ||
name: "iOS build on branch ${{ github.event.ref }} for commit ${{ github.event.inputs.commit }}" | ||
runs-on: macos-14 | ||
|
||
steps: | ||
- name: Output link to real commit | ||
run: echo ${{ github.repository }}/commit/${{ github.event.inputs.commit }} | ||
|
||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
ref: ${{ github.event.inputs.commit }} | ||
|
||
- uses: dtolnay/rust-toolchain@stable | ||
with: | ||
targets: x86_64-apple-ios,aarch64-apple-ios,aarch64-apple-ios-sim | ||
|
||
- uses: actions/cache@v4 | ||
with: | ||
path: | | ||
~/.cargo/registry | ||
~/.cargo/git | ||
target | ||
key: ${{ runner.os }}-ios-cargo-${{ hashFiles('**/Cargo.lock') }} | ||
|
||
- run: | | ||
cd query-engine/query-engine-c-abi | ||
make ios | ||
- uses: actions/upload-artifact@v4 | ||
with: | ||
name: ios | ||
path: | | ||
${{ github.workspace }}/query-engine/query-engine-c-abi/ios/* | ||
build-android: | ||
# Do not change `name`, prisma-engines Buildkite build job depends on this name ending with the commit | ||
name: "Android build on branch ${{ github.event.ref }} for commit ${{ github.event.inputs.commit }}" | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Output link to real commit | ||
run: echo ${{ github.repository }}/commit/${{ github.event.inputs.commit }} | ||
|
||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
ref: ${{ github.event.inputs.commit }} | ||
- uses: dtolnay/rust-toolchain@stable | ||
with: | ||
targets: aarch64-linux-android,armv7-linux-androideabi,x86_64-linux-android,i686-linux-android | ||
|
||
- uses: nttld/setup-ndk@v1 | ||
with: | ||
ndk-version: r26d | ||
|
||
- uses: actions/cache@v4 | ||
with: | ||
path: | | ||
~/.cargo/registry | ||
~/.cargo/git | ||
target | ||
key: ${{ runner.os }}-android-cargo-${{ hashFiles('**/Cargo.lock') }} | ||
|
||
- run: | | ||
cd query-engine/query-engine-c-abi | ||
make android | ||
- uses: actions/upload-artifact@v4 | ||
with: | ||
name: android | ||
path: | | ||
${{ github.workspace }}/query-engine/query-engine-c-abi/android/* | ||
combine-artifacts: | ||
# Do not change `name`, prisma-engines Buildkite build job depends on this name ending with the commit | ||
name: "Combine iOS and Android artifacts on branch ${{ github.event.ref }} for commit ${{ github.event.inputs.commit }}" | ||
runs-on: ubuntu-latest | ||
needs: | ||
- build-ios | ||
- build-android | ||
steps: | ||
- name: Download artifacts | ||
uses: actions/download-artifact@v4 | ||
|
||
- name: Upload combined artifact | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: binaries | ||
path: | | ||
${{ github.workspace }}/ios | ||
${{ github.workspace }}/android | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
QueryEngine.xcframework | ||
ios | ||
android | ||
simulator_fat | ||
# Artifacts of the C ABI engine | ||
*.tar.gz | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.