From 22a57b7aac513264d74f501dd6093b6fcf4d6c54 Mon Sep 17 00:00:00 2001 From: bitsandfoxes Date: Wed, 16 Apr 2025 16:39:00 +0200 Subject: [PATCH 1/3] container? --- .github/workflows/ci.yml | 4 +++- .github/workflows/sdk.yml | 7 +++++-- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 49c323c6b..0b376c31a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -34,13 +34,15 @@ jobs: - target: Linux # Build using older Linux version to preserve sdk compatibility with old GLIBC # See discussion in https://github.com/getsentry/sentry-unity/issues/1730 for more details - host: ubuntu-20.04 + host: ubuntu-latest + container_image: ubuntu:20.04 - target: Windows host: windows-latest uses: ./.github/workflows/sdk.yml with: target: ${{ matrix.target }} runsOn: ${{ matrix.host }} + container_image: ${{ matrix.container_image }} build-unity-sdk: name: Build Unity SDK diff --git a/.github/workflows/sdk.yml b/.github/workflows/sdk.yml index a63d11880..21d57d67d 100644 --- a/.github/workflows/sdk.yml +++ b/.github/workflows/sdk.yml @@ -7,6 +7,9 @@ on: target: required: true type: string + container_image: + required: false + type: string env: DOTNET_CLI_TELEMETRY_OPTOUT: 1 @@ -15,6 +18,7 @@ env: jobs: build: runs-on: ${{ inputs.runsOn }} + container: ${{ inputs.container_image != '' && format('{0}', inputs.container_image) || null }} timeout-minutes: 30 steps: - uses: actions/checkout@v3 @@ -50,13 +54,12 @@ jobs: key: sdk=${{ inputs.target }}-${{ hashFiles('submodules-status', 'package/package.json', 'Directory.Build.targets', 'sdk-static/**') }} - name: Installing Linux Dependencies - if: ${{ inputs.target == 'Linux' && steps.cache.outputs.cache-hit != 'true' }} + if: ${{ inputs.target == 'Linux'}} run: | sudo apt-get update sudo apt-get install zlib1g-dev libcurl4-openssl-dev libssl-dev - name: Build - if: steps.cache.outputs.cache-hit != 'true' run: | git submodule update --init --recursive ${{ steps.env.outputs.submodules }} dotnet msbuild /t:Build${{ inputs.target }}SDK /p:Configuration=Release /p:OutDir=other src/Sentry.Unity From e3801ed365f917afe408adc2c268b4b1fe822005 Mon Sep 17 00:00:00 2001 From: bitsandfoxes Date: Wed, 16 Apr 2025 17:34:01 +0200 Subject: [PATCH 2/3] no sudo --- .github/workflows/sdk.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/sdk.yml b/.github/workflows/sdk.yml index 21d57d67d..8990b2246 100644 --- a/.github/workflows/sdk.yml +++ b/.github/workflows/sdk.yml @@ -56,8 +56,8 @@ jobs: - name: Installing Linux Dependencies if: ${{ inputs.target == 'Linux'}} run: | - sudo apt-get update - sudo apt-get install zlib1g-dev libcurl4-openssl-dev libssl-dev + apt-get update + apt-get install zlib1g-dev libcurl4-openssl-dev libssl-dev - name: Build run: | From 61d67e1b719a9f8568e4ac328832a3dcd7299961 Mon Sep 17 00:00:00 2001 From: bitsandfoxes Date: Wed, 16 Apr 2025 17:45:19 +0200 Subject: [PATCH 3/3] no more questions --- .github/workflows/sdk.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/sdk.yml b/.github/workflows/sdk.yml index 8990b2246..22acc073f 100644 --- a/.github/workflows/sdk.yml +++ b/.github/workflows/sdk.yml @@ -57,7 +57,7 @@ jobs: if: ${{ inputs.target == 'Linux'}} run: | apt-get update - apt-get install zlib1g-dev libcurl4-openssl-dev libssl-dev + apt-get install -y zlib1g-dev libcurl4-openssl-dev libssl-dev - name: Build run: |