Skip to content

Commit

Permalink
Update to .NET 9
Browse files Browse the repository at this point in the history
  • Loading branch information
gunndabad committed Dec 20, 2024
1 parent 4e78117 commit e53166a
Show file tree
Hide file tree
Showing 54 changed files with 6,537 additions and 6,596 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/dbml.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,10 @@ jobs:

- uses: extractions/setup-just@v2

- uses: actions/setup-dotnet@v4
with:
dotnet-version: '9.0.x'

- name: Install postgresql-client
run: |
sudo sh -c 'echo "deb http://apt.postgresql.org/pub/repos/apt $(lsb_release -cs)-pgdg main" > /etc/apt/sources.list.d/pgdg.list'
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,10 @@ jobs:

- uses: extractions/setup-just@v2

- uses: actions/setup-dotnet@v4
with:
dotnet-version: '9.0.x'

- name: Get Docker image tag
id: image_tags
run: |
Expand Down
10 changes: 9 additions & 1 deletion .github/workflows/pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,10 @@ jobs:

- uses: extractions/setup-just@v2

- uses: actions/setup-dotnet@v4
with:
dotnet-version: '9.0.x'

- name: Install tools
run: just install-tools

Expand Down Expand Up @@ -127,6 +131,10 @@ jobs:

- uses: extractions/setup-just@v2

- uses: actions/setup-dotnet@v4
with:
dotnet-version: '9.0.x'

- name: Install tools
run: just install-tools

Expand Down Expand Up @@ -159,7 +167,7 @@ jobs:
- name: Install Playwright if required
run: |
if [[ "$PROJECT_NAME" =~ .*EndToEndTests ]]; then
pwsh ./bin/Release/net8.0/playwright.ps1 install chromium
pwsh ./bin/Release/net9.0/playwright.ps1 install chromium
fi
working-directory: TeachingRecordSystem/tests/${{ matrix.project }}
env:
Expand Down
13 changes: 8 additions & 5 deletions TeachingRecordSystem/.config/dotnet-tools.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,22 +3,25 @@
"isRoot": true,
"tools": {
"dotnet-format": {
"version": "8.0.453106",
"version": "9.0.520307",
"commands": [
"dotnet-format"
]
],
"rollForward": false
},
"dotnet-ef": {
"version": "8.0.8",
"version": "9.0.0",
"commands": [
"dotnet-ef"
]
],
"rollForward": false
},
"microsoft.web.librarymanager.cli": {
"version": "2.1.175",
"commands": [
"libman"
]
],
"rollForward": false
}
}
}
3 changes: 2 additions & 1 deletion TeachingRecordSystem/Directory.Build.props
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<Project>
<PropertyGroup>
<LangVersion>12.0</LangVersion>
<LangVersion>13.0</LangVersion>
<TreatWarningsAsErrors Condition="'$(Configuration)' == 'Release'">true</TreatWarningsAsErrors>
<Nullable>enable</Nullable>
<ImplicitUsings>enable</ImplicitUsings>
Expand All @@ -10,6 +10,7 @@

<UserSecretsId>TeachingRecordSystem</UserSecretsId>
<UserSecretsId Condition="'$(IsTestProject)' == 'true'">TeachingRecordSystemTests</UserSecretsId>
<TargetFramework Condition="'$(IsSourceGeneratorProject)' != 'true'">net9.0</TargetFramework>
</PropertyGroup>

<ItemGroup>
Expand Down
54 changes: 27 additions & 27 deletions TeachingRecordSystem/Directory.Packages.props
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@
</PropertyGroup>
<ItemGroup>
<PackageVersion Include="AngleSharp" Version="1.1.2" />
<PackageVersion Include="AspNetCore.HealthChecks.NpgSql" Version="8.0.0" />
<PackageVersion Include="AspNetCore.HealthChecks.Redis" Version="8.0.1" />
<PackageVersion Include="AspNetCore.HealthChecks.NpgSql" Version="9.0.0" />
<PackageVersion Include="AspNetCore.HealthChecks.Redis" Version="9.0.0" />
<PackageVersion Include="AutoMapper" Version="13.0.1" />
<PackageVersion Include="Azure.Extensions.AspNetCore.DataProtection.Blobs" Version="1.3.4" />
<PackageVersion Include="Azure.Storage.Blobs" Version="12.19.1" />
Expand All @@ -17,11 +17,11 @@
<PackageVersion Include="CloudNative.CloudEvents.SystemTextJson" Version="2.8.0" />
<PackageVersion Include="CsvHelper" Version="30.1.0" />
<PackageVersion Include="dbup-sqlserver" Version="5.0.37" />
<PackageVersion Include="Dfe.Analytics" Version="0.2.5" />
<PackageVersion Include="Dfe.Analytics" Version="0.2.6" />
<PackageVersion Include="DistributedLock.Azure" Version="1.0.0" />
<PackageVersion Include="DistributedLock.FileSystem" Version="1.0.2" />
<PackageVersion Include="EFCore.NamingConventions" Version="8.0.3" />
<PackageVersion Include="EntityFrameworkCore.Projectables" Version="3.0.4" />
<PackageVersion Include="EFCore.NamingConventions" Version="9.0.0" />
<PackageVersion Include="EntityFrameworkCore.Projectables" Version="4.0.0" />
<PackageVersion Include="Faker.Net" Version="2.0.154" />
<PackageVersion Include="FakeXrmEasy.v9" Version="3.5.0" />
<PackageVersion Include="FluentValidation.AspNetCore" Version="11.3.0" />
Expand All @@ -39,24 +39,24 @@
<PackageVersion Include="JustEat.HttpClientInterception" Version="4.3.0" />
<PackageVersion Include="LinqKit" Version="1.2.5" />
<PackageVersion Include="MediatR" Version="12.2.0" />
<PackageVersion Include="Microsoft.AspNetCore.Authentication.JwtBearer" Version="8.0.7" />
<PackageVersion Include="Microsoft.AspNetCore.Authentication.OpenIdConnect" Version="8.0.7" />
<PackageVersion Include="Microsoft.AspNetCore.Diagnostics.EntityFrameworkCore" Version="8.0.8" />
<PackageVersion Include="Microsoft.AspNetCore.Mvc.Testing" Version="8.0.7" />
<PackageVersion Include="Microsoft.AspNetCore.Authentication.JwtBearer" Version="9.0.0" />
<PackageVersion Include="Microsoft.AspNetCore.Authentication.OpenIdConnect" Version="9.0.0" />
<PackageVersion Include="Microsoft.AspNetCore.Diagnostics.EntityFrameworkCore" Version="9.0.0" />
<PackageVersion Include="Microsoft.AspNetCore.Mvc.Testing" Version="9.0.0" />
<PackageVersion Include="Microsoft.Data.SqlClient" Version="5.2.2" />
<PackageVersion Include="Microsoft.EntityFrameworkCore.Design" Version="8.0.7" />
<PackageVersion Include="Microsoft.EntityFrameworkCore.InMemory" Version="8.0.7" />
<PackageVersion Include="Microsoft.EntityFrameworkCore.Relational" Version="8.0.10" />
<PackageVersion Include="Microsoft.EntityFrameworkCore.Design" Version="9.0.0" />
<PackageVersion Include="Microsoft.EntityFrameworkCore.InMemory" Version="9.0.0" />
<PackageVersion Include="Microsoft.EntityFrameworkCore.Relational" Version="9.0.0" />
<PackageVersion Include="Microsoft.Extensions.Azure" Version="1.7.5" />
<PackageVersion Include="Microsoft.Extensions.Caching.StackExchangeRedis" Version="8.0.8" />
<PackageVersion Include="Microsoft.Extensions.Configuration.Abstractions" Version="8.0.0" />
<PackageVersion Include="Microsoft.Extensions.Configuration.Binder" Version="8.0.2" />
<PackageVersion Include="Microsoft.Extensions.Configuration.Json" Version="8.0.0" />
<PackageVersion Include="Microsoft.Extensions.Configuration.UserSecrets" Version="8.0.0" />
<PackageVersion Include="Microsoft.Extensions.Hosting" Version="8.0.0" />
<PackageVersion Include="Microsoft.Extensions.Http" Version="8.0.0" />
<PackageVersion Include="Microsoft.Extensions.Options.ConfigurationExtensions" Version="8.0.0" />
<PackageVersion Include="Microsoft.Extensions.Options.DataAnnotations" Version="8.0.0" />
<PackageVersion Include="Microsoft.Extensions.Configuration.Abstractions" Version="9.0.0" />
<PackageVersion Include="Microsoft.Extensions.Configuration.Binder" Version="9.0.0" />
<PackageVersion Include="Microsoft.Extensions.Configuration.Json" Version="9.0.0" />
<PackageVersion Include="Microsoft.Extensions.Configuration.UserSecrets" Version="9.0.0" />
<PackageVersion Include="Microsoft.Extensions.Hosting" Version="9.0.0" />
<PackageVersion Include="Microsoft.Extensions.Http" Version="9.0.0" />
<PackageVersion Include="Microsoft.Extensions.Options.ConfigurationExtensions" Version="9.0.0" />
<PackageVersion Include="Microsoft.Extensions.Options.DataAnnotations" Version="9.0.0" />
<PackageVersion Include="Microsoft.Identity.Web" Version="2.17.0" />
<PackageVersion Include="Microsoft.Identity.Web.GraphServiceClientBeta" Version="2.16.0" />
<PackageVersion Include="Microsoft.NET.Test.Sdk" Version="17.9.0" />
Expand All @@ -65,16 +65,16 @@
<PackageVersion Include="Microsoft.PowerPlatform.Dataverse.Client.Dynamics" Version="1.1.27" />
<PackageVersion Include="Microsoft.VisualStudio.Threading.Analyzers" Version="17.12.19" />
<PackageVersion Include="Moq" Version="4.20.70" />
<PackageVersion Include="Npgsql.DependencyInjection" Version="8.0.3" />
<PackageVersion Include="Npgsql.EntityFrameworkCore.PostgreSQL" Version="8.0.10" />
<PackageVersion Include="Npgsql.DependencyInjection" Version="9.0.2" />
<PackageVersion Include="Npgsql.EntityFrameworkCore.PostgreSQL" Version="9.0.2" />
<PackageVersion Include="NSign.AspNetCore" Version="1.1.0" />
<PackageVersion Include="NSign.Client" Version="1.1.0" />
<PackageVersion Include="NSign.SignatureProviders" Version="1.1.0" />
<PackageVersion Include="OpenIddict.AspNetCore" Version="5.2.0" />
<PackageVersion Include="OpenIddict.EntityFrameworkCore" Version="5.2.0" />
<PackageVersion Include="OpenIddict.AspNetCore" Version="6.0.0" />
<PackageVersion Include="OpenIddict.EntityFrameworkCore" Version="6.0.0" />
<PackageVersion Include="Optional" Version="4.0.0" />
<PackageVersion Include="Parquet.Net" Version="4.24.0" />
<PackageVersion Include="PdfSharpCore" Version="1.3.62" />
<PackageVersion Include="Parquet.Net" Version="5.0.2" />
<PackageVersion Include="PdfSharpCore" Version="1.3.65" />
<PackageVersion Include="Polly.Core" Version="8.2.1" />
<PackageVersion Include="prometheus-net.AspNetCore" Version="8.2.1" />
<PackageVersion Include="RedisRateLimiting.AspNetCore" Version="1.1.0" />
Expand All @@ -96,7 +96,7 @@
<PackageVersion Include="Swashbuckle.AspNetCore.Annotations" Version="6.6.2" />
<PackageVersion Include="System.CommandLine" Version="2.0.0-beta4.22272.1" />
<PackageVersion Include="System.Linq.Async" Version="6.0.1" />
<PackageVersion Include="System.Net.Http.Json" Version="8.0.0" />
<PackageVersion Include="System.Net.Http.Json" Version="9.0.0" />
<PackageVersion Include="System.Reactive" Version="6.0.1" />
<PackageVersion Include="xunit" Version="2.6.2" />
<PackageVersion Include="xunit.assert" Version="2.9.0" />
Expand Down
12 changes: 6 additions & 6 deletions TeachingRecordSystem/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
# syntax=docker/dockerfile:1
FROM mcr.microsoft.com/dotnet/aspnet:8.0-alpine3.18
FROM mcr.microsoft.com/dotnet/aspnet:9.0-alpine3.20
ARG GIT_SHA
ENV SENTRY_RELEASE ${GIT_SHA}
ENV GIT_SHA ${GIT_SHA}
ENV ASPNETCORE_HTTP_PORTS 3000
COPY src/TeachingRecordSystem.Api/bin/Release/net8.0/publish/ Apps/Api/
COPY src/TeachingRecordSystem.Cli/bin/Release/net8.0/publish/ Apps/TrsCli/
COPY src/TeachingRecordSystem.SupportUi/bin/Release/net8.0/publish/ Apps/SupportUi/
COPY src/TeachingRecordSystem.Worker/bin/Release/net8.0/publish/ Apps/Worker/
COPY src/TeachingRecordSystem.AuthorizeAccess/bin/Release/net8.0/publish/ Apps/AuthorizeAccess/
COPY src/TeachingRecordSystem.Api/bin/Release/net9.0/publish/ Apps/Api/
COPY src/TeachingRecordSystem.Cli/bin/Release/net9.0/publish/ Apps/TrsCli/
COPY src/TeachingRecordSystem.SupportUi/bin/Release/net9.0/publish/ Apps/SupportUi/
COPY src/TeachingRecordSystem.Worker/bin/Release/net9.0/publish/ Apps/Worker/
COPY src/TeachingRecordSystem.AuthorizeAccess/bin/Release/net9.0/publish/ Apps/AuthorizeAccess/
COPY db.sh Apps/db.sh
WORKDIR /Apps

Expand Down
Binary file removed TeachingRecordSystem/lib/Dfe.Analytics.0.2.5.nupkg
Binary file not shown.
Binary file not shown.
4 changes: 2 additions & 2 deletions TeachingRecordSystem/nuget.config
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<packageSources>
<add key="dotnet8" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet8/nuget/v3/index.json" />
<add key="dotnet9" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet9/nuget/v3/index.json" />
<add key="lib" value="lib" />
</packageSources>
<packageSourceMapping>
<packageSource key="nuget.org">
<package pattern="*" />
</packageSource>
<packageSource key="dotnet8">
<packageSource key="dotnet9">
<package pattern="dotnet-format" />
</packageSource>
<packageSource key="lib">
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
<Project Sdk="Microsoft.NET.Sdk.Web">

<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="AspNetCore.HealthChecks.Redis" />
<PackageReference Include="AutoMapper" />
Expand Down
Loading

0 comments on commit e53166a

Please sign in to comment.