diff --git a/.github/workflows/publish-abac-nuget.yml b/.github/workflows/publish-abac-nuget.yml new file mode 100644 index 00000000..9a176a03 --- /dev/null +++ b/.github/workflows/publish-abac-nuget.yml @@ -0,0 +1,45 @@ +name: Pack and publish Altinn.Authorization.ABAC nuget package + +on: + release: + types: + - published + +jobs: + build-pack: + if: startsWith(github.ref, 'refs/tags/Altinn.Authorization.ABAC-') + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + with: + fetch-depth: 0 + + - name: Setup .NET + uses: actions/setup-dotnet@v4 + with: + dotnet-version: | + 8.0.x + + - name: Build + working-directory: src/Altinn.Authorization.ABAC + run: | + dotnet build --configuration Release + + - name: Pack Altinn.Authorization.ABAC + working-directory: src/Altinn.Authorization.ABAC + run: | + dotnet pack --configuration Release --no-build + + - name: Create artifact + uses: actions/upload-artifact@v4 + with: + name: nuget package + path: src/Altinn.Authorization.ABAC/bin/Release/*.nupkg + if-no-files-found: error + + - name: publish Altinn.Authorization.ABAC + env: + NUGET_API_KEY: ${{ secrets.NUGET_API_KEY }} + working-directory: src/Altinn.Authorization.ABAC + run: | + dotnet nuget push bin/Release/*.nupkg --source https://api.nuget.org/v3/index.json --api-key "$NUGET_API_KEY" diff --git a/.github/workflows/publish-pep-nuget.yml b/.github/workflows/publish-pep-nuget.yml new file mode 100644 index 00000000..3f5d7f04 --- /dev/null +++ b/.github/workflows/publish-pep-nuget.yml @@ -0,0 +1,45 @@ +name: Pack and publish Altinn.Common.PEP nuget package + +on: + release: + types: + - published + +jobs: + build-pack: + if: startsWith(github.ref, 'refs/tags/Altinn.Common.PEP-') + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + with: + fetch-depth: 0 + + - name: Setup .NET + uses: actions/setup-dotnet@v4 + with: + dotnet-version: | + 8.0.x + + - name: Build + working-directory: src/Altinn.Common.PEP/Altinn.Common.PEP + run: | + dotnet build --configuration Release + + - name: Pack Altinn.Common.PEP + working-directory: src/Altinn.Common.PEP/Altinn.Common.PEP + run: | + dotnet pack --configuration Release --no-build + + - name: Create artifact + uses: actions/upload-artifact@v4 + with: + name: nuget package + path: src/Altinn.Common.PEP/Altinn.Common.PEP/bin/Release/*.nupkg + if-no-files-found: error + + - name: publish Altinn.Common.PEP + env: + NUGET_API_KEY: ${{ secrets.NUGET_API_KEY }} + working-directory: src/Altinn.Common.PEP/Altinn.Common.PEP + run: | + dotnet nuget push bin/Release/*.nupkg --source https://api.nuget.org/v3/index.json --api-key "$NUGET_API_KEY" \ No newline at end of file diff --git a/src/Altinn.Authorization.ABAC/Altinn.Authorization.ABAC.csproj b/src/Altinn.Authorization.ABAC/Altinn.Authorization.ABAC.csproj index d7818456..cecc5048 100644 --- a/src/Altinn.Authorization.ABAC/Altinn.Authorization.ABAC.csproj +++ b/src/Altinn.Authorization.ABAC/Altinn.Authorization.ABAC.csproj @@ -1,16 +1,14 @@ - + netstandard2.0 Library - 0.0.0.8 - 0.0.0.8 {C9ABF5DB-928C-4280-B587-13E6DCE010BC} Altinn.Authorization.ABAC - 0.0.8 + 0.0.8 Altinn;Authorization;ABAC Attribute Based Access Control library for .Net Core implementing XACML 3.0 xml and JSON Profile. @@ -19,12 +17,13 @@ Altinn Platform Contributors - git - https://github.com/Altinn/altinn-studio - true - snupkg + + + + + all diff --git a/src/Altinn.Common.PEP/Altinn.Common.PEP/Altinn.Common.PEP.csproj b/src/Altinn.Common.PEP/Altinn.Common.PEP/Altinn.Common.PEP.csproj index 928dd415..63bdc673 100644 --- a/src/Altinn.Common.PEP/Altinn.Common.PEP/Altinn.Common.PEP.csproj +++ b/src/Altinn.Common.PEP/Altinn.Common.PEP/Altinn.Common.PEP.csproj @@ -17,12 +17,13 @@ Altinn Platform Contributors - git - https://github.com/altinn/altinn-authorization - true - snupkg + + + + +