From 9a916d5a10b1e7f2ab342b092730836670cc951c Mon Sep 17 00:00:00 2001 From: Omar Boukli-Hacene Date: Sat, 8 Jun 2024 22:39:17 +0200 Subject: [PATCH] ci: Update CI configuration to .NET 8.0 --- .github/workflows/build-and-test.yml | 10 ++++++---- .github/workflows/dotnet-security-scan.yml | 18 ++++++++++++++++++ .github/workflows/publish.yml | 4 ++-- .github/workflows/resharper-inspectcode.yml | 2 +- 4 files changed, 27 insertions(+), 7 deletions(-) diff --git a/.github/workflows/build-and-test.yml b/.github/workflows/build-and-test.yml index 7d4371b..c49493e 100644 --- a/.github/workflows/build-and-test.yml +++ b/.github/workflows/build-and-test.yml @@ -53,7 +53,9 @@ jobs: env: AKTABOOK_ENVIRONMENT: Test AKTABOOK_INTEGRATION_TEST_ENVIRONMENT: Test - BUS_HOST_PID_FILE: src/Aktabook.Bus/bin/Release/net6.0/aktabook-bus.pid + BUS_BIN_DIR: src/Aktabook.Bus/bin/Release/net8.0/ + BUS_HOST_PID_FILE: src/Aktabook.Bus/bin/Release/net8.0/aktabook-bus.pid + BUS_LOGS_DIR: src/Aktabook.Bus/bin/Release/net8.0/Logs/ RequesterServiceBus__RabbitMQConnectionOptions__HostName: localhost RequesterServiceBus__RabbitMQConnectionOptions__Password: ${{ secrets.RABBITMQ_INTEGRATION_TEST_PASSWORD }} RequesterServiceBus__RabbitMQConnectionOptions__PortNumber: 5672 @@ -240,7 +242,7 @@ jobs: --background coverage_session ./Aktabook.Bus - working-directory: src/Aktabook.Bus/bin/Release/net6.0/ + working-directory: ${{ env.BUS_BIN_DIR }} - name: Wait for bus readiness check env: @@ -339,7 +341,7 @@ jobs: with: if-no-files-found: error name: bus-logs - path: src/Aktabook.Bus/bin/Release/net6.0/Logs + path: ${{ env.BUS_LOGS_DIR }} - name: Upload public API logs if: ${{ always() }} @@ -347,7 +349,7 @@ jobs: with: if-no-files-found: error name: public-api-logs - path: src/Aktabook.Bus/bin/Release/net6.0/Logs + path: ${{ env.BUS_LOGS_DIR }} unit_test: name: Unit test diff --git a/.github/workflows/dotnet-security-scan.yml b/.github/workflows/dotnet-security-scan.yml index 108245b..f62e9f2 100644 --- a/.github/workflows/dotnet-security-scan.yml +++ b/.github/workflows/dotnet-security-scan.yml @@ -42,6 +42,15 @@ jobs: with: persist-credentials: false + - name: Set up .NET SDK + uses: actions/setup-dotnet@v4 + with: + cache: true + cache-dependency-path: |- + src/**/packages.lock.json + test/**/packages.lock.json + global-json-file: global.json + - name: Install scanner run: >- dotnet tool install security-scan @@ -64,6 +73,15 @@ jobs: with: persist-credentials: false + - name: Set up .NET SDK + uses: actions/setup-dotnet@v4 + with: + cache: true + cache-dependency-path: |- + src/**/packages.lock.json + test/**/packages.lock.json + global-json-file: global.json + - name: Restores dependencies env: DOTNET_NUGET_SIGNATURE_VERIFICATION: true diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index c0f16d0..6e7c1e7 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -28,8 +28,8 @@ jobs: name: Publish for Ubuntu runs-on: ubuntu-latest env: - AKTABOOK_DOTNET_FRAMWORK: net6.0 - AKTABOOK_DOTNET_RUNTIME_TARGET: ubuntu.22.04-x64 + AKTABOOK_DOTNET_FRAMWORK: net8.0 + AKTABOOK_DOTNET_RUNTIME_TARGET: linux-x64 AKTABOOK_PUBLISH_PATH_ROOT: ${{ github.workspace }}/publish DOTNET_CLI_TELEMETRY_OPTOUT: true DOTNET_NUGET_SIGNATURE_VERIFICATION: true diff --git a/.github/workflows/resharper-inspectcode.yml b/.github/workflows/resharper-inspectcode.yml index f57266c..fbffe37 100644 --- a/.github/workflows/resharper-inspectcode.yml +++ b/.github/workflows/resharper-inspectcode.yml @@ -49,4 +49,4 @@ jobs: mono: solution: ./Aktabook.sln telemetry-optout: True - tool-version: "2024.1.0-rc01" + tool-version: "2024.1.3"