diff --git a/.github/workflows/build-and-analyze.yml b/.github/workflows/build-and-analyze.yml index 37a2f4c5..4cc76821 100644 --- a/.github/workflows/build-and-analyze.yml +++ b/.github/workflows/build-and-analyze.yml @@ -32,7 +32,7 @@ jobs: uses: actions/setup-dotnet@v3 with: dotnet-version: | - 7.0.x + 8.0.x - name: Set up Java uses: actions/setup-java@v3 with: diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index df9a0fe9..ea56d269 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -29,11 +29,11 @@ jobs: steps: - name: Checkout repository uses: actions/checkout@v4 - - name: Setup .NET 7.0.* SDK + - name: Setup .NET 8.0.* SDK uses: actions/setup-dotnet@v3 with: dotnet-version: | - 7.0.x + 8.0.x - name: Initialize CodeQL uses: github/codeql-action/init@v2 with: @@ -42,7 +42,7 @@ jobs: # By default, queries listed here will override any specified in a config file. # Prefix the list here with "+" to use these queries and those in the config file. # queries: ./path/to/local/query, your-org/your-repo/queries@main - + - name: Autobuild uses: github/codeql-action/autobuild@v2 # - name: Build notifications core diff --git a/Dockerfile b/Dockerfile index 3cdebc62..5573e290 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM mcr.microsoft.com/dotnet/sdk:7.0.404-alpine3.18 AS build +FROM mcr.microsoft.com/dotnet/sdk:8.0.100-1-alpine3.18 AS build WORKDIR /app # Copy csproj and restore as distinct layers @@ -13,7 +13,7 @@ COPY src ./src RUN dotnet publish -c Release -o out ./src/Altinn.Notifications/Altinn.Notifications.csproj # Build runtime image -FROM mcr.microsoft.com/dotnet/aspnet:7.0.14-alpine3.18 AS final +FROM mcr.microsoft.com/dotnet/aspnet:8.0.0-alpine3.18 AS final WORKDIR /app EXPOSE 5090 diff --git a/src/Altinn.Notifications.Core/Altinn.Notifications.Core.csproj b/src/Altinn.Notifications.Core/Altinn.Notifications.Core.csproj index dcaddc3a..f23e9953 100644 --- a/src/Altinn.Notifications.Core/Altinn.Notifications.Core.csproj +++ b/src/Altinn.Notifications.Core/Altinn.Notifications.Core.csproj @@ -1,7 +1,7 @@  - net7.0 + net8.0 enable enable true @@ -10,10 +10,10 @@ - - - - + + + + diff --git a/src/Altinn.Notifications.Integrations/Altinn.Notifications.Integrations.csproj b/src/Altinn.Notifications.Integrations/Altinn.Notifications.Integrations.csproj index b323c8ba..00aab300 100644 --- a/src/Altinn.Notifications.Integrations/Altinn.Notifications.Integrations.csproj +++ b/src/Altinn.Notifications.Integrations/Altinn.Notifications.Integrations.csproj @@ -1,7 +1,7 @@  - net7.0 + net8.0 enable enable true @@ -9,9 +9,9 @@ - - - + + + diff --git a/src/Altinn.Notifications.Persistence/Altinn.Notifications.Persistence.csproj b/src/Altinn.Notifications.Persistence/Altinn.Notifications.Persistence.csproj index 9219c08d..861a66ca 100644 --- a/src/Altinn.Notifications.Persistence/Altinn.Notifications.Persistence.csproj +++ b/src/Altinn.Notifications.Persistence/Altinn.Notifications.Persistence.csproj @@ -1,7 +1,7 @@  - net7.0 + net8.0 enable enable true @@ -11,11 +11,11 @@ - - - - - + + + + + diff --git a/src/Altinn.Notifications.Persistence/Extensions/ServiceCollectionExtensions.cs b/src/Altinn.Notifications.Persistence/Extensions/ServiceCollectionExtensions.cs index 558ab07c..81a9595a 100644 --- a/src/Altinn.Notifications.Persistence/Extensions/ServiceCollectionExtensions.cs +++ b/src/Altinn.Notifications.Persistence/Extensions/ServiceCollectionExtensions.cs @@ -32,7 +32,9 @@ public static IServiceCollection AddPostgresRepositories(this IServiceCollection .AddSingleton() .AddSingleton() .AddSingleton() - .AddNpgsqlDataSource(connectionString, builder => builder.EnableParameterLogging(settings.LogParameters)); + .AddNpgsqlDataSource(connectionString, builder => + builder.EnableParameterLogging(settings.LogParameters) + .EnableDynamicJson()); } /// diff --git a/src/Altinn.Notifications/Altinn.Notifications.csproj b/src/Altinn.Notifications/Altinn.Notifications.csproj index a6d47fc6..63bca446 100644 --- a/src/Altinn.Notifications/Altinn.Notifications.csproj +++ b/src/Altinn.Notifications/Altinn.Notifications.csproj @@ -1,7 +1,7 @@  - net7.0 + net8.0 enable enable True @@ -12,7 +12,7 @@ - + @@ -22,7 +22,7 @@ - + diff --git a/test/Altinn.Notifications.IntegrationTests/Altinn.Notifications.IntegrationTests.csproj b/test/Altinn.Notifications.IntegrationTests/Altinn.Notifications.IntegrationTests.csproj index 7b5a6de3..c5bd0b10 100644 --- a/test/Altinn.Notifications.IntegrationTests/Altinn.Notifications.IntegrationTests.csproj +++ b/test/Altinn.Notifications.IntegrationTests/Altinn.Notifications.IntegrationTests.csproj @@ -1,7 +1,7 @@  - net7.0 + net8.0 enable enable diff --git a/test/Altinn.Notifications.Tests/Altinn.Notifications.Tests.csproj b/test/Altinn.Notifications.Tests/Altinn.Notifications.Tests.csproj index a434e831..6e3999ad 100644 --- a/test/Altinn.Notifications.Tests/Altinn.Notifications.Tests.csproj +++ b/test/Altinn.Notifications.Tests/Altinn.Notifications.Tests.csproj @@ -1,14 +1,14 @@  - net7.0 + net8.0 enable false - +