Skip to content

Commit 909e829

Browse files
nitin27mayNitin Singh
andauthored
angular and .net upgrade (#8)
Co-authored-by: Nitin Singh <nitin@Nitins-Laptop.local>
1 parent ebfa33f commit 909e829

File tree

14 files changed

+3999
-3937
lines changed

14 files changed

+3999
-3937
lines changed

Api/Application/Application.csproj

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,18 @@
1-
<Project Sdk="Microsoft.NET.Sdk">
1+
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFramework>net6.0</TargetFramework>
4+
<TargetFramework>net7.0</TargetFramework>
55
</PropertyGroup>
66
<ItemGroup>
7-
<PackageReference Include="AutoMapper" Version="11.0.1" />
8-
<PackageReference Include="AutoMapper.Extensions.Microsoft.DependencyInjection" Version="11.0.0" />
9-
<PackageReference Include="FluentValidation" Version="11.2.2" />
10-
<PackageReference Include="FluentValidation.DependencyInjectionExtensions" Version="11.2.2" />
11-
<PackageReference Include="Microsoft.EntityFrameworkCore.InMemory" Version="6.0.9" />
12-
<PackageReference Include="MediatR.Extensions.Microsoft.DependencyInjection" Version="10.0.1" />
13-
<PackageReference Include="Microsoft.EntityFrameworkCore" Version="6.0.9" />
14-
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
15-
<PackageReference Include="System.Text.Json" Version="6.0.6" />
7+
<PackageReference Include="AutoMapper" Version="12.0.0" />
8+
<PackageReference Include="AutoMapper.Extensions.Microsoft.DependencyInjection" Version="12.0.0" />
9+
<PackageReference Include="FluentValidation" Version="11.4.0" />
10+
<PackageReference Include="FluentValidation.DependencyInjectionExtensions" Version="11.4.0" />
11+
<PackageReference Include="Microsoft.EntityFrameworkCore.InMemory" Version="7.0.0" />
12+
<PackageReference Include="MediatR.Extensions.Microsoft.DependencyInjection" Version="11.0.0" />
13+
<PackageReference Include="Microsoft.EntityFrameworkCore" Version="7.0.0" />
14+
<PackageReference Include="Newtonsoft.Json" Version="13.0.2" />
15+
<PackageReference Include="System.Text.Json" Version="7.0.0" />
1616
</ItemGroup>
1717
<ItemGroup>
1818
<ProjectReference Include="..\Domain\Domain.csproj" />

Api/Application/Behaviours/ValidationBehaviour.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ public ValidationBehavior(IEnumerable<IValidator<TRequest>> validators)
1717
_validators = validators;
1818
}
1919

20-
public async Task<TResponse> Handle(TRequest request, CancellationToken cancellationToken, RequestHandlerDelegate<TResponse> next)
20+
public async Task<TResponse> Handle(TRequest request, RequestHandlerDelegate<TResponse> next, CancellationToken cancellationToken)
2121
{
2222
if (_validators.Any())
2323
{

Api/Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#See https://aka.ms/containerfastmode to understand how Visual Studio uses this Dockerfile to build your images for faster debugging.
22

3-
FROM mcr.microsoft.com/dotnet/aspnet:6.0.9 AS base
3+
FROM mcr.microsoft.com/dotnet/aspnet:7 AS base
44
WORKDIR /app
55
EXPOSE 8000
66
ENV ASPNETCORE_URLS=http://+:8000
@@ -9,7 +9,7 @@ RUN groupadd -g 2000 dotnet \
99
USER dotnet
1010

1111

12-
FROM mcr.microsoft.com/dotnet/sdk:6.0.401 AS build
12+
FROM mcr.microsoft.com/dotnet/sdk:7 AS build
1313
WORKDIR /src
1414
COPY ["WebApi/WebApi.csproj", "WebApi/"]
1515
COPY ["Application/Application.csproj", "Application/"]

Api/Domain/Domain.csproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
<Project Sdk="Microsoft.NET.Sdk">
1+
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFramework>net6.0</TargetFramework>
4+
<TargetFramework>net7.0</TargetFramework>
55
</PropertyGroup>
66

77
<ItemGroup>

Api/Infrastructure.Identity/Infrastructure.Identity.csproj

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,23 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22
<PropertyGroup>
3-
<TargetFramework>net6.0</TargetFramework>
3+
<TargetFramework>net7.0</TargetFramework>
44
<LangVersion>latest</LangVersion>
55
</PropertyGroup>
66
<ItemGroup>
7-
<PackageReference Include="Microsoft.AspNetCore.Authentication.JwtBearer" Version="6.0.9" />
8-
<PackageReference Include="Microsoft.AspNetCore.Diagnostics.EntityFrameworkCore" Version="6.0.9" />
9-
<PackageReference Include="Microsoft.AspNetCore.Identity.EntityFrameworkCore" Version="6.0.9" />
10-
<PackageReference Include="Microsoft.EntityFrameworkCore.Tools" Version="6.0.9">
7+
<PackageReference Include="Microsoft.AspNetCore.Authentication.JwtBearer" Version="7.0.0" />
8+
<PackageReference Include="Microsoft.AspNetCore.Diagnostics.EntityFrameworkCore" Version="7.0.0" />
9+
<PackageReference Include="Microsoft.AspNetCore.Identity.EntityFrameworkCore" Version="7.0.0" />
10+
<PackageReference Include="Microsoft.EntityFrameworkCore.Tools" Version="7.0.0">
1111
<PrivateAssets>all</PrivateAssets>
1212
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
1313
</PackageReference>
14-
<PackageReference Include="microsoft.extensions.dependencyinjection" Version="6.0.0" />
15-
<PackageReference Include="MimeKit" Version="3.4.1" />
16-
<PackageReference Include="Microsoft.EntityFrameworkCore.InMemory" Version="6.0.9" />
17-
<PackageReference Include="Npgsql.EntityFrameworkCore.PostgreSQL" Version="6.0.7" />
14+
<PackageReference Include="microsoft.extensions.dependencyinjection" Version="7.0.0" />
15+
<PackageReference Include="MimeKit" Version="3.4.3" />
16+
<PackageReference Include="Microsoft.EntityFrameworkCore.InMemory" Version="7.0.0" />
17+
<PackageReference Include="Npgsql.EntityFrameworkCore.PostgreSQL" Version="7.0.0" />
1818
<PackageReference Include="Npgsql.EntityFrameworkCore.PostgreSQL.Design" Version="1.1.0" />
19-
<PackageReference Include="System.IdentityModel.Tokens.Jwt" Version="6.23.1" />
20-
<PackageReference Include="Microsoft.Extensions.Options.ConfigurationExtensions" Version="6.0.0" />
19+
<PackageReference Include="System.IdentityModel.Tokens.Jwt" Version="6.25.1" />
20+
<PackageReference Include="Microsoft.Extensions.Options.ConfigurationExtensions" Version="7.0.0" />
2121
</ItemGroup>
2222
<ItemGroup>
2323
<ProjectReference Include="..\Application\Application.csproj" />

Api/Infrastructure.Persistence/Infrastructure.Persistence.csproj

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFramework>net6.0</TargetFramework>
4+
<TargetFramework>net7.0</TargetFramework>
55
<Version>1.1.0</Version>
66
</PropertyGroup>
77

88

99

1010
<ItemGroup>
11-
<PackageReference Include="Microsoft.AspNetCore.Identity.EntityFrameworkCore" Version="6.0.9" />
12-
<PackageReference Include="Microsoft.EntityFrameworkCore.InMemory" Version="6.0.9" />
13-
<PackageReference Include="Microsoft.Extensions.Options.ConfigurationExtensions" Version="6.0.0" />
14-
<PackageReference Include="Npgsql.EntityFrameworkCore.PostgreSQL" Version="6.0.7" />
11+
<PackageReference Include="Microsoft.AspNetCore.Identity.EntityFrameworkCore" Version="7.0.0" />
12+
<PackageReference Include="Microsoft.EntityFrameworkCore.InMemory" Version="7.0.0" />
13+
<PackageReference Include="Microsoft.Extensions.Options.ConfigurationExtensions" Version="7.0.0" />
14+
<PackageReference Include="Npgsql.EntityFrameworkCore.PostgreSQL" Version="7.0.0" />
1515
<PackageReference Include="Npgsql.EntityFrameworkCore.PostgreSQL.Design" Version="1.1.0" />
1616
</ItemGroup>
1717

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
<Project Sdk="Microsoft.NET.Sdk">
1+
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFramework>net6.0</TargetFramework>
4+
<TargetFramework>net7.0</TargetFramework>
55
<Version>1.1.0</Version>
66
<LangVersion>latest</LangVersion>
77
</PropertyGroup>
@@ -10,9 +10,9 @@
1010
<ProjectReference Include="..\Application\Application.csproj" />
1111
</ItemGroup>
1212
<ItemGroup>
13-
<PackageReference Include="MailKit" Version="3.4.1" />
14-
<PackageReference Include="Microsoft.Extensions.Options.ConfigurationExtensions" Version="6.0.0" />
15-
<PackageReference Include="MimeKit" Version="3.4.1" />
13+
<PackageReference Include="MailKit" Version="3.4.3" />
14+
<PackageReference Include="Microsoft.Extensions.Options.ConfigurationExtensions" Version="7.0.0" />
15+
<PackageReference Include="MimeKit" Version="3.4.3" />
1616
<PackageReference Include="SendGrid" Version="9.28.1" />
1717
</ItemGroup>
1818
</Project>

Api/WebApi/WebApi.csproj

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,27 @@
11
<Project Sdk="Microsoft.NET.Sdk.Web">
22
<PropertyGroup>
3-
<TargetFramework>net6.0</TargetFramework>
3+
<TargetFramework>net7.0</TargetFramework>
44
<UserSecretsId>13baa941-0ae9-449c-8360-2fa7150a14fa</UserSecretsId>
55
<DockerDefaultTargetOS>Linux</DockerDefaultTargetOS>
66
</PropertyGroup>
77
<ItemGroup>
8-
<PackageReference Include="Microsoft.EntityFrameworkCore.Tools" Version="6.0.9">
8+
<PackageReference Include="Microsoft.EntityFrameworkCore.Tools" Version="7.0.0">
99
<PrivateAssets>all</PrivateAssets>
1010
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
1111
</PackageReference>
1212
<PackageReference Include="Microsoft.VisualStudio.Azure.Containers.Tools.Targets" Version="1.11.1" />
13-
<PackageReference Include="Microsoft.VisualStudio.Web.CodeGeneration.Design" Version="6.0.9" />
14-
<PackageReference Include="NSwag.Annotations" Version="13.17.0" />
13+
<PackageReference Include="Microsoft.VisualStudio.Web.CodeGeneration.Design" Version="7.0.0" />
14+
<PackageReference Include="NSwag.Annotations" Version="13.18.0" />
1515
<PackageReference Include="Swashbuckle.AspNetCore" Version="6.4.0" />
1616
<PackageReference Include="Swashbuckle.AspNetCore.Swagger" Version="6.4.0" />
17-
<PackageReference Include="Serilog.AspNetCore" Version="6.0.1" />
17+
<PackageReference Include="Serilog.AspNetCore" Version="6.1.0" />
1818
<PackageReference Include="Serilog.Enrichers.Environment" Version="2.2.0" />
1919
<PackageReference Include="Serilog.Enrichers.Process" Version="2.0.2" />
2020
<PackageReference Include="Serilog.Enrichers.Thread" Version="3.1.0" />
2121
<PackageReference Include="Serilog.Settings.Configuration" Version="3.4.0" />
22-
<PackageReference Include="Serilog.Sinks.MSSqlServer" Version="5.7.1" />
22+
<PackageReference Include="Serilog.Sinks.MSSqlServer" Version="6.0.0" />
2323
<PackageReference Include="Microsoft.AspNetCore.Mvc.Versioning" Version="5.0.0" />
24-
<PackageReference Include="Microsoft.AspNetCore.Mvc.NewtonsoftJson" Version="6.0.9" />
24+
<PackageReference Include="Microsoft.AspNetCore.Mvc.NewtonsoftJson" Version="7.0.0" />
2525
<PackageReference Include="FluentValidation.AspNetCore" Version="11.2.2" />
2626
</ItemGroup>
2727
<ItemGroup>

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Full Stack (dotnet, angular and postgres) boilerplate with Docker
22
### About (Dotnet - Angular - PostgresSQL)
3-
This project is intended to provide a starting point for building full-stack web applicatioin. The stack is made of Dotnet(6) WebApi, Angular (14), PostgresSQL. The focus of this project to show case the possible way to run a real application (Dotnet, Angular and PostgresSQL) using docker for development enviornment and produciton mode.
3+
This project is intended to provide a starting point for building full-stack web applicatioin. The stack is made of Dotnet(7) WebApi, Angular (15.0.3), PostgresSQL. The focus of this project to show case the possible way to run a real application (Dotnet, Angular and PostgresSQL) using docker for development enviornment and produciton mode.
44

55
This is a simple web application. It has working user registration, login page and there is a complete example of CRUD which contains example for Angular Routing and dotnet rest api samples. Also, rest services are secure using JWT.
66

@@ -27,7 +27,7 @@ The apps written in the following JavaScript frameworks/libraries:
2727
| **WebApi** | [Rest Api using **dotnet**](https://github.com/nitin27may/angular-dotnet-core-docker/tree/master/WebApi) |
2828

2929
### Built With
30-
#### Angular (14.2.2)
30+
#### Angular (15.0.3)
3131

3232
The fronend of this project is developed in Angular. As we are using Server Side Rendering (SSR) we have used Nodejs alpine image in place of other lightweight docker image like nginx to run Angular app.
3333

@@ -44,7 +44,7 @@ Also, it has sample code for Auth guard, services, http interceptors, resolver a
4444
**[Dockerfile for Production](/frontend/Dockerfile)**
4545
**[Dockerfile for Development](/frontend/debug.dockerfile)**
4646

47-
#### Dotnet (6.0.0)
47+
#### Dotnet (7.0.0)
4848

4949
Rest APis of this project is devloped using dotnet
5050

0 commit comments

Comments
 (0)