From 5546519756979f3be85b945716ab2669c772da63 Mon Sep 17 00:00:00 2001 From: "Charan sai Uggam (Accenture International Limited)" Date: Thu, 29 Oct 2026 14:06:04 +0530 Subject: [PATCH] Fix issues in Mythos ICM --- .../release-extensions-distributedcache.yml | 35 ++++++++++++++--- .github/workflows/release-sdk.yml | 39 ++++++++++++++----- 2 files changed, 60 insertions(+), 14 deletions(-) diff --git a/.github/workflows/release-extensions-distributedcache.yml b/.github/workflows/release-extensions-distributedcache.yml index de7eef0..5ae9aa1 100644 --- a/.github/workflows/release-extensions-distributedcache.yml +++ b/.github/workflows/release-extensions-distributedcache.yml @@ -2,13 +2,18 @@ name: Release-Extension-DistributedCache on: workflow_dispatch: +permissions: + contents: read + jobs: - release: + build: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 + with: + persist-credentials: false - name: Setup .NET - uses: actions/setup-dotnet@v1 + uses: actions/setup-dotnet@67a3573c9a986a3f9c594539f4ab511d57bb3ce9 # v4.3.1 with: dotnet-version: 5.0.x - name: Install dependencies @@ -18,6 +23,26 @@ jobs: - name: Test run: dotnet test src/sdk/Extensions/Microsoft.Extensions.Caching.UnifiedRedisPlatform/Microsoft.Extensions.Caching.UnifiedRedisPlatform.csproj --no-restore --verbosity normal - name: Pack - run: dotnet pack src/sdk/Extensions/Microsoft.Extensions.Caching.UnifiedRedisPlatform/Microsoft.Extensions.Caching.UnifiedRedisPlatform.csproj + run: dotnet pack src/sdk/Extensions/Microsoft.Extensions.Caching.UnifiedRedisPlatform/Microsoft.Extensions.Caching.UnifiedRedisPlatform.csproj --output ./artifacts + - name: Upload package + uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2 + with: + name: nupkg + path: artifacts/*.nupkg + if-no-files-found: error + + # Publish runs without checking out repo code, so build/test-time code never has access to the NuGet key. + publish: + needs: build + runs-on: ubuntu-latest + environment: nuget-publish + steps: + - name: Download package + uses: actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # v4.3.0 + with: + name: nupkg + path: artifacts - name: Publish - run: dotnet nuget push **/*.nupkg --api-key ${{ secrets.NuGet_API_Key }} --source https://api.nuget.org/v3/index.json + run: dotnet nuget push "artifacts/*.nupkg" --api-key "$NUGET_API_KEY" --source https://api.nuget.org/v3/index.json + env: + NUGET_API_KEY: ${{ secrets.NuGet_API_Key }} \ No newline at end of file diff --git a/.github/workflows/release-sdk.yml b/.github/workflows/release-sdk.yml index c170e8b..643b78b 100644 --- a/.github/workflows/release-sdk.yml +++ b/.github/workflows/release-sdk.yml @@ -1,23 +1,44 @@ -name: Release on: workflow_dispatch: +permissions: + contents: read + jobs: - release: + build: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 + with: + persist-credentials: false - name: Setup .NET - uses: actions/setup-dotnet@v1 + uses: actions/setup-dotnet@67a3573c9a986a3f9c594539f4ab511d57bb3ce9 # v4.3.1 with: dotnet-version: 5.0.x - name: Install dependencies - run: dotnet restore src/sdk/Core/Microsoft.UnifiedRedisPlatform.Core.csproj - - name: Build - run: dotnet build src/sdk/Core/Microsoft.UnifiedRedisPlatform.Core.csproj --no-restore - name: Test run: dotnet test src/sdk/Core/Microsoft.UnifiedRedisPlatform.Core.csproj --no-restore --verbosity normal - name: Pack - run: dotnet pack src/sdk/Core/Microsoft.UnifiedRedisPlatform.Core.csproj + run: dotnet pack src/sdk/Core/Microsoft.UnifiedRedisPlatform.Core.csproj --output ./artifacts + - name: Upload package + uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2 + with: + name: nupkg + path: artifacts/*.nupkg + if-no-files-found: error + + # Publish runs without checking out repo code, so build/test-time code never has access to the NuGet key. + publish: + needs: build + runs-on: ubuntu-latest + environment: nuget-publish + steps: + - name: Download package + uses: actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # v4.3.0 + with: + name: nupkg + path: artifacts - name: Publish - run: dotnet nuget push **/*.nupkg --api-key ${{ secrets.NuGet_API_Key }} --source https://api.nuget.org/v3/index.json + run: dotnet nuget push "artifacts/*.nupkg" --api-key "$NUGET_API_KEY" --source https://api.nuget.org/v3/index.json + env: + NUGET_API_KEY: ${{ secrets.NuGet_API_Key }} \ No newline at end of file