Skip to content

Commit

Permalink
feat: Minimal working configuration to update project for .NET 7.0.0 …
Browse files Browse the repository at this point in the history
…preview

note: Has issues with port forwarding with devcontainers, and still investigating
  • Loading branch information
Pofay committed Apr 24, 2023
1 parent 5f2d24d commit 07352c5
Show file tree
Hide file tree
Showing 9 changed files with 35 additions and 35 deletions.
2 changes: 1 addition & 1 deletion .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
@@ -1 +1 @@
FROM --platform=linux/amd64 mcr.microsoft.com/devcontainers/dotnet:0-6.0
FROM --platform=linux/amd64 mcr.microsoft.com/devcontainers/dotnet:0-7.0
8 changes: 4 additions & 4 deletions API.Test/API.Test.csproj
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net6.0</TargetFramework>
<TargetFramework>net7.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<Nullable>disable</Nullable>

<IsPackable>false</IsPackable>
</PropertyGroup>
Expand All @@ -23,8 +23,8 @@
</PackageReference>
</ItemGroup>

<ItemGroup>
<ProjectReference Include="..\API\API.csproj" />
<ItemGroup>
<ProjectReference Include="..\API\API.csproj" />
</ItemGroup>

</Project>
8 changes: 4 additions & 4 deletions Application.Test/Application.Test.csproj
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net6.0</TargetFramework>
<TargetFramework>net7.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<Nullable>disable</Nullable>

<IsPackable>false</IsPackable>
</PropertyGroup>
Expand All @@ -23,8 +23,8 @@
</PackageReference>
</ItemGroup>

<ItemGroup>
<ProjectReference Include="..\Application\Application.csproj" />
<ItemGroup>
<ProjectReference Include="..\Application\Application.csproj" />
</ItemGroup>

</Project>
22 changes: 11 additions & 11 deletions Application/Application.csproj
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
<Project Sdk="Microsoft.NET.Sdk">

<ItemGroup>
<ProjectReference Include="..\Domain\Domain.csproj" />
<ProjectReference Include="..\Persistence\Persistence.csproj" />
<ItemGroup>
<ProjectReference Include="..\Domain\Domain.csproj" />
<ProjectReference Include="..\Persistence\Persistence.csproj" />
</ItemGroup>

<ItemGroup>
<PackageReference Include="AutoMapper.Extensions.Microsoft.DependencyInjection" Version="11.0.0" />
<PackageReference Include="FluentResults" Version="3.15.1" />
<PackageReference Include="FluentValidation.AspNetCore" Version="11.2.2" />
<PackageReference Include="FluentValidation.DependencyInjectionExtensions" Version="11.3.0" />
<PackageReference Include="MediatR.Extensions.Microsoft.DependencyInjection" Version="10.0.1" />
<ItemGroup>
<PackageReference Include="AutoMapper.Extensions.Microsoft.DependencyInjection" Version="12.0.0" />
<PackageReference Include="FluentResults" Version="3.15.1" />
<PackageReference Include="FluentValidation.AspNetCore" Version="11.2.2" />
<PackageReference Include="FluentValidation.DependencyInjectionExtensions" Version="11.3.0" />
<PackageReference Include="MediatR.Extensions.Microsoft.DependencyInjection" Version="11.0.0" />
</ItemGroup>

<PropertyGroup>
<TargetFramework>net6.0</TargetFramework>
<TargetFramework>net7.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<Nullable>disable</Nullable>
</PropertyGroup>

</Project>
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM mcr.microsoft.com/dotnet/sdk:6.0 AS build-env
FROM mcr.microsoft.com/dotnet/sdk:7.0 AS build-env
WORKDIR /app
EXPOSE 8080

Expand Down Expand Up @@ -32,7 +32,7 @@ COPY client-app/ .
RUN npm run build:prod

# build the final image
FROM mcr.microsoft.com/dotnet/aspnet:6.0
FROM mcr.microsoft.com/dotnet/aspnet:7.0
WORKDIR /app
COPY --from=build-env /app/out .
COPY --from=build-client /app/client-app/dist ./wwwroot
Expand Down
8 changes: 4 additions & 4 deletions Domain.Test/Domain.Test.csproj
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net6.0</TargetFramework>
<TargetFramework>net7.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<Nullable>disable</Nullable>

<IsPackable>false</IsPackable>
</PropertyGroup>
Expand All @@ -22,8 +22,8 @@
</PackageReference>
</ItemGroup>

<ItemGroup>
<ProjectReference Include="..\Domain\Domain.csproj" />
<ItemGroup>
<ProjectReference Include="..\Domain\Domain.csproj" />
</ItemGroup>

</Project>
6 changes: 3 additions & 3 deletions Domain/Domain.csproj
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net6.0</TargetFramework>
<TargetFramework>net7.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<Nullable>disable</Nullable>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.AspNetCore.Identity.EntityFrameworkCore" Version="6.0.6" />
<PackageReference Include="Microsoft.AspNetCore.Identity.EntityFrameworkCore" Version="7.0.0" />
</ItemGroup>

</Project>
6 changes: 3 additions & 3 deletions Infrastructure/Infrastructure.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@
<ProjectReference Include="..\Application\Application.csproj" />
</ItemGroup>

<ItemGroup>
<PackageReference Include="CloudinaryDotNet" Version="1.20.0" />
<ItemGroup>
<PackageReference Include="CloudinaryDotNet" Version="1.20.0" />
</ItemGroup>

<PropertyGroup>
<TargetFramework>net6.0</TargetFramework>
<TargetFramework>net7.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>disable</Nullable>
</PropertyGroup>
Expand Down
6 changes: 3 additions & 3 deletions Persistence/Persistence.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
</ItemGroup>

<ItemGroup>
<PackageReference Include="Microsoft.EntityFrameworkCore" Version="6.0.6" />
<PackageReference Include="Npgsql.EntityFrameworkCore.PostgreSQL" Version="6.0.5" />
<PackageReference Include="Microsoft.EntityFrameworkCore" Version="7.0.0" />
<PackageReference Include="Npgsql.EntityFrameworkCore.PostgreSQL" Version="7.0.0" />
</ItemGroup>

<PropertyGroup>
<TargetFramework>net6.0</TargetFramework>
<TargetFramework>net7.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
</PropertyGroup>

Expand Down

0 comments on commit 07352c5

Please sign in to comment.