From b403ac9682de6073e10132343e56b016d27ad003 Mon Sep 17 00:00:00 2001 From: Bart Louwers Date: Fri, 23 Feb 2024 21:49:05 +0100 Subject: [PATCH] Free GitHub runners (#2132) --- .github/actionlint.yaml | 1 - .github/workflows/android-ci.yml | 50 ++++++++++++++++++++++---------- .github/workflows/ios-ci.yml | 8 ++--- .github/workflows/linux-ci.yml | 2 +- 4 files changed, 40 insertions(+), 21 deletions(-) diff --git a/.github/actionlint.yaml b/.github/actionlint.yaml index a5c10e5b8..36ae1928d 100644 --- a/.github/actionlint.yaml +++ b/.github/actionlint.yaml @@ -1,7 +1,6 @@ self-hosted-runner: # Labels of self-hosted runner in array of strings. labels: - - MapLibre_Native_Linux_16_core - macos-14 # can be removed once actionlint is updated # Configuration variables in array of strings defined in your repository or # organization. `null` means disabling configuration variables check. diff --git a/.github/workflows/android-ci.yml b/.github/workflows/android-ci.yml index e8b1e9a2e..269b76615 100644 --- a/.github/workflows/android-ci.yml +++ b/.github/workflows/android-ci.yml @@ -33,7 +33,7 @@ jobs: files_yaml_from_source_file: .github/changed-files.yml android-build: - runs-on: ${{ github.event.pull_request && !github.event.pull_request.draft && 'MapLibre_Native_Linux_16_core' || 'ubuntu-22.04' }} + runs-on: ubuntu-22.04 needs: - pre_job if: needs.pre_job.outputs.should_skip != 'true' @@ -193,7 +193,39 @@ jobs: name: uploadsEnv path: uploads.env - # render test + - name: Store debug artifacts + uses: actions/upload-artifact@v4 + with: + name: debug-artifacts + path: | + MapboxGLAndroidSDKTestApp/build/outputs/apk/debug + MapboxGLAndroidSDK/build/reports/lint-results.html + MapboxGLAndroidSDK/lint-baseline.xml + MapboxGLAndroidSDKTestApp/build/reports/lint-results.html + MapboxGLAndroidSDKTestApp/build/reports/lint-results.xml + MapboxGLAndroidSDKTestApp/lint-baseline.xml + MapboxGLAndroidSDK/build/intermediates/cmake/debug/obj + + android-build-render-test: + runs-on: ubuntu-latest + needs: + - pre_job + if: needs.pre_job.outputs.should_skip != 'true' + steps: + - uses: actions/checkout@v4 + with: + submodules: recursive + fetch-depth: 0 + + - uses: hendrikmuhs/ccache-action@v1.2 + with: + key: ${{ github.job }} + + - uses: actions/setup-java@v4 + with: + distribution: "temurin" + java-version: "17" + - name: Build Render Test App run: | ./gradlew assemble assembleAndroidTest @@ -210,19 +242,6 @@ jobs: ./render-test/android/RenderTestsApp.apk ./render-test/android/RenderTests.apk - - name: Store debug artifacts - uses: actions/upload-artifact@v4 - with: - name: debug-artifacts - path: | - MapboxGLAndroidSDKTestApp/build/outputs/apk/debug - MapboxGLAndroidSDK/build/reports/lint-results.html - MapboxGLAndroidSDK/lint-baseline.xml - MapboxGLAndroidSDKTestApp/build/reports/lint-results.html - MapboxGLAndroidSDKTestApp/build/reports/lint-results.xml - MapboxGLAndroidSDKTestApp/lint-baseline.xml - MapboxGLAndroidSDK/build/intermediates/cmake/debug/obj - android-instrumentation-test: needs: android-build @@ -265,6 +284,7 @@ jobs: needs: - pre_job - android-build + - android-build-render-test steps: - name: Mark result as failed if: needs.android-build.result != 'success' diff --git a/.github/workflows/ios-ci.yml b/.github/workflows/ios-ci.yml index 73fc3991f..8a3b0e72e 100644 --- a/.github/workflows/ios-ci.yml +++ b/.github/workflows/ios-ci.yml @@ -210,7 +210,7 @@ jobs: if: github.event.inputs.release == 'full' run: | echo version="$(head VERSION)" >> "$GITHUB_ENV" - echo changelog_version_heading="## ${{ env.version }}" >> "$GITHUB_ENV" + echo changelog_version_heading="## $(head VERSION)" >> "$GITHUB_ENV" - name: Get version (pre-release) if: github.event.inputs.release == 'pre' @@ -274,9 +274,9 @@ jobs: -H "Authorization: token ${{ steps.generate_token.outputs.token }}" \ -H "X-GitHub-Api-Version: 2022-11-28" \ https://api.github.com/repos/maplibre/maplibre-gl-native-distribution/actions/workflows/$release_workflow_id/dispatches \ - -d '{"ref":"main","inputs":{ \ - "changelog_url": "https://maplibre-native.s3.eu-central-1.amazonaws.com/changelogs/ios-${{ env.version }}.md", \ - "version":"${{ env.version }}", \ + -d '{"ref":"main","inputs":{ + "changelog_url": "https://maplibre-native.s3.eu-central-1.amazonaws.com/changelogs/ios-${{ env.version }}.md", + "version":"${{ env.version }}", "download_url":"${{ fromJSON(steps.github_release.outputs.assets)[0].browser_download_url }}"}}' - name: Release (CocoaPods) diff --git a/.github/workflows/linux-ci.yml b/.github/workflows/linux-ci.yml index c09363d29..d5cfd857e 100644 --- a/.github/workflows/linux-ci.yml +++ b/.github/workflows/linux-ci.yml @@ -51,7 +51,7 @@ jobs: fail-fast: true matrix: renderer: [legacy, drawable] - runs-on: ${{ github.event.pull_request && !github.event.pull_request.draft && 'MapLibre_Native_Linux_16_core' || 'ubuntu-22.04' }} + runs-on: ubuntu-22.04 steps: - uses: actions/checkout@v4 with: