mirror of
https://github.com/aaronpo97/the-biergarten-app.git
synced 2026-02-16 10:42:08 +00:00
create Infrastructure directory
This commit is contained in:
@@ -101,7 +101,7 @@ services:
|
|||||||
condition: service_completed_successfully
|
condition: service_completed_successfully
|
||||||
build:
|
build:
|
||||||
context: ./src/Core
|
context: ./src/Core
|
||||||
dockerfile: Repository/Repository.Tests/Dockerfile
|
dockerfile: Infrastructure/Infrastructure.Repository/Repository.Tests/Dockerfile
|
||||||
args:
|
args:
|
||||||
BUILD_CONFIGURATION: Release
|
BUILD_CONFIGURATION: Release
|
||||||
environment:
|
environment:
|
||||||
|
|||||||
@@ -19,7 +19,9 @@
|
|||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\..\Domain\Domain.csproj" />
|
<ProjectReference Include="..\..\Domain\Domain.csproj" />
|
||||||
<ProjectReference Include="..\..\Repository\Repository.Core\Repository.Core.csproj" />
|
<ProjectReference
|
||||||
|
Include="..\..\Infrastructure\Infrastructure.Repository\Repository.Core\Repository.Core.csproj" />
|
||||||
|
<ProjectReference Include="..\..\Infrastructure\Infrastructure.Jwt\Infrastructure.Jwt.csproj" />
|
||||||
<ProjectReference Include="..\..\Service\Service.Core\Service.Core.csproj" />
|
<ProjectReference Include="..\..\Service\Service.Core\Service.Core.csproj" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
|
|||||||
@@ -9,7 +9,10 @@ FROM mcr.microsoft.com/dotnet/sdk:10.0 AS build
|
|||||||
ARG BUILD_CONFIGURATION=Release
|
ARG BUILD_CONFIGURATION=Release
|
||||||
WORKDIR /src
|
WORKDIR /src
|
||||||
COPY ["API/API.Core/API.Core.csproj", "API/API.Core/"]
|
COPY ["API/API.Core/API.Core.csproj", "API/API.Core/"]
|
||||||
COPY ["Repository/Repository.Core/Repository.Core.csproj", "Repository/Repository.Core/"]
|
COPY ["Domain/Domain.csproj", "Domain/"]
|
||||||
|
COPY ["Infrastructure/Infrastructure.Repository/Repository.Core/Repository.Core.csproj", "Infrastructure/Infrastructure.Repository/Repository.Core/"]
|
||||||
|
COPY ["Infrastructure/Infrastructure.Jwt/Infrastructure.Jwt.csproj", "Infrastructure/Infrastructure.Jwt/"]
|
||||||
|
COPY ["Infrastructure/Infrastructure.PasswordHashing/Infrastructure.PasswordHashing.csproj", "Infrastructure/Infrastructure.PasswordHashing/"]
|
||||||
COPY ["Service/Service.Core/Service.Core.csproj", "Service/Service.Core/"]
|
COPY ["Service/Service.Core/Service.Core.csproj", "Service/Service.Core/"]
|
||||||
RUN dotnet restore "API/API.Core/API.Core.csproj"
|
RUN dotnet restore "API/API.Core/API.Core.csproj"
|
||||||
COPY . .
|
COPY . .
|
||||||
|
|||||||
@@ -3,7 +3,10 @@ ARG BUILD_CONFIGURATION=Release
|
|||||||
WORKDIR /src
|
WORKDIR /src
|
||||||
COPY ["API/API.Core/API.Core.csproj", "API/API.Core/"]
|
COPY ["API/API.Core/API.Core.csproj", "API/API.Core/"]
|
||||||
COPY ["API/API.Specs/API.Specs.csproj", "API/API.Specs/"]
|
COPY ["API/API.Specs/API.Specs.csproj", "API/API.Specs/"]
|
||||||
COPY ["Repository/Repository.Core/Repository.Core.csproj", "Repository/Repository.Core/"]
|
COPY ["Domain/Domain.csproj", "Domain/"]
|
||||||
|
COPY ["Infrastructure/Infrastructure.Repository/Repository.Core/Repository.Core.csproj", "Infrastructure/Infrastructure.Repository/Repository.Core/"]
|
||||||
|
COPY ["Infrastructure/Infrastructure.Jwt/Infrastructure.Jwt.csproj", "Infrastructure/Infrastructure.Jwt/"]
|
||||||
|
COPY ["Infrastructure/Infrastructure.PasswordHashing/Infrastructure.PasswordHashing.csproj", "Infrastructure/Infrastructure.PasswordHashing/"]
|
||||||
COPY ["Service/Service.Core/Service.Core.csproj", "Service/Service.Core/"]
|
COPY ["Service/Service.Core/Service.Core.csproj", "Service/Service.Core/"]
|
||||||
RUN dotnet restore "API/API.Specs/API.Specs.csproj"
|
RUN dotnet restore "API/API.Specs/API.Specs.csproj"
|
||||||
COPY . .
|
COPY . .
|
||||||
|
|||||||
@@ -10,9 +10,13 @@
|
|||||||
<Folder Name="/Domain/">
|
<Folder Name="/Domain/">
|
||||||
<Project Path="Domain/Domain.csproj" />
|
<Project Path="Domain/Domain.csproj" />
|
||||||
</Folder>
|
</Folder>
|
||||||
<Folder Name="/Repository/">
|
<Folder Name="/Infrastructure/">
|
||||||
<Project Path="Repository/Repository.Core/Repository.Core.csproj" />
|
<Project Path="Infrastructure/Infrastructure.Jwt/Infrastructure.Jwt.csproj" />
|
||||||
<Project Path="Repository/Repository.Tests/Repository.Tests.csproj" />
|
<Project
|
||||||
|
Path="Infrastructure/Infrastructure.PasswordHashing/Infrastructure.PasswordHashing.csproj" />
|
||||||
|
<Project Path="Infrastructure/Infrastructure.Repository/Repository.Core/Repository.Core.csproj" />
|
||||||
|
<Project
|
||||||
|
Path="Infrastructure/Infrastructure.Repository/Repository.Tests/Repository.Tests.csproj" />
|
||||||
</Folder>
|
</Folder>
|
||||||
<Folder Name="/Service/">
|
<Folder Name="/Service/">
|
||||||
<Project Path="Service/Service.Core/Service.Core.csproj" />
|
<Project Path="Service/Service.Core/Service.Core.csproj" />
|
||||||
|
|||||||
@@ -19,6 +19,7 @@
|
|||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\..\Domain\Domain.csproj" />
|
<ProjectReference Include="..\..\Domain\Domain.csproj" />
|
||||||
<ProjectReference Include="..\..\Repository\Repository.Core\Repository.Core.csproj" />
|
<ProjectReference
|
||||||
|
Include="..\..\Infrastructure\Infrastructure.Repository\Repository.Core\Repository.Core.csproj" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
</Project>
|
</Project>
|
||||||
|
|||||||
@@ -0,0 +1,13 @@
|
|||||||
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
<PropertyGroup>
|
||||||
|
<TargetFramework>net10.0</TargetFramework>
|
||||||
|
<ImplicitUsings>enable</ImplicitUsings>
|
||||||
|
<Nullable>enable</Nullable>
|
||||||
|
<RootNamespace>Service.Core.Jwt</RootNamespace>
|
||||||
|
</PropertyGroup>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<PackageReference Include="Microsoft.IdentityModel.JsonWebTokens" Version="8.2.1" />
|
||||||
|
<PackageReference Include="System.IdentityModel.Tokens.Jwt" Version="8.2.1" />
|
||||||
|
</ItemGroup>
|
||||||
|
</Project>
|
||||||
@@ -0,0 +1,12 @@
|
|||||||
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
<PropertyGroup>
|
||||||
|
<TargetFramework>net10.0</TargetFramework>
|
||||||
|
<ImplicitUsings>enable</ImplicitUsings>
|
||||||
|
<Nullable>enable</Nullable>
|
||||||
|
<RootNamespace>Service.Core.Password</RootNamespace>
|
||||||
|
</PropertyGroup>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<PackageReference Include="Konscious.Security.Cryptography.Argon2" Version="1.3.1" />
|
||||||
|
</ItemGroup>
|
||||||
|
</Project>
|
||||||
@@ -15,6 +15,6 @@
|
|||||||
<PackageReference Include="Microsoft.Extensions.Configuration.Abstractions" Version="8.0.0" />
|
<PackageReference Include="Microsoft.Extensions.Configuration.Abstractions" Version="8.0.0" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\..\Domain\Domain.csproj" />
|
<ProjectReference Include="..\..\..\Domain\Domain.csproj" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
</Project>
|
</Project>
|
||||||
@@ -0,0 +1,15 @@
|
|||||||
|
FROM mcr.microsoft.com/dotnet/sdk:10.0 AS build
|
||||||
|
ARG BUILD_CONFIGURATION=Release
|
||||||
|
WORKDIR /src
|
||||||
|
COPY ["Domain/Domain.csproj", "Domain/"]
|
||||||
|
COPY ["Infrastructure/Infrastructure.Repository/Repository.Core/Repository.Core.csproj", "Infrastructure/Infrastructure.Repository/Repository.Core/"]
|
||||||
|
COPY ["Infrastructure/Infrastructure.Repository/Repository.Tests/Repository.Tests.csproj", "Infrastructure/Infrastructure.Repository/Repository.Tests/"]
|
||||||
|
RUN dotnet restore "Infrastructure/Infrastructure.Repository/Repository.Tests/Repository.Tests.csproj"
|
||||||
|
COPY . .
|
||||||
|
WORKDIR "/src/Infrastructure/Infrastructure.Repository/Repository.Tests"
|
||||||
|
RUN dotnet build "./Repository.Tests.csproj" -c $BUILD_CONFIGURATION -o /app/build
|
||||||
|
|
||||||
|
FROM build AS final
|
||||||
|
RUN mkdir -p /app/test-results
|
||||||
|
WORKDIR /src/Infrastructure/Infrastructure.Repository/Repository.Tests
|
||||||
|
ENTRYPOINT ["dotnet", "test", "./Repository.Tests.csproj", "-c", "Release", "--logger", "trx;LogFileName=/app/test-results/repository-tests.trx"]
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
using System.Data.Common;
|
|
||||||
using Repository.Core.Sql;
|
|
||||||
|
|
||||||
namespace Repository.Tests.Database;
|
|
||||||
|
|
||||||
internal class TestConnectionFactory(DbConnection conn) : ISqlConnectionFactory
|
|
||||||
{
|
|
||||||
private readonly DbConnection _conn = conn;
|
|
||||||
public DbConnection CreateConnection() => _conn;
|
|
||||||
}
|
|
||||||
@@ -1,14 +0,0 @@
|
|||||||
FROM mcr.microsoft.com/dotnet/sdk:10.0 AS build
|
|
||||||
ARG BUILD_CONFIGURATION=Release
|
|
||||||
WORKDIR /src
|
|
||||||
COPY ["Repository/Repository.Core/Repository.Core.csproj", "Repository/Repository.Core/"]
|
|
||||||
COPY ["Repository/Repository.Tests/Repository.Tests.csproj", "Repository/Repository.Tests/"]
|
|
||||||
RUN dotnet restore "Repository/Repository.Tests/Repository.Tests.csproj"
|
|
||||||
COPY . .
|
|
||||||
WORKDIR "/src/Repository/Repository.Tests"
|
|
||||||
RUN dotnet build "./Repository.Tests.csproj" -c $BUILD_CONFIGURATION -o /app/build
|
|
||||||
|
|
||||||
FROM build AS final
|
|
||||||
RUN mkdir -p /app/test-results
|
|
||||||
WORKDIR /src/Repository/Repository.Tests
|
|
||||||
ENTRYPOINT ["dotnet", "test", "./Repository.Tests.csproj", "-c", "Release", "--logger", "trx;LogFileName=/app/test-results/repository-tests.trx"]
|
|
||||||
@@ -12,6 +12,9 @@
|
|||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\..\Domain\Domain.csproj" />
|
<ProjectReference Include="..\..\Domain\Domain.csproj" />
|
||||||
<ProjectReference Include="..\..\Repository\Repository.Core\Repository.Core.csproj" />
|
<ProjectReference
|
||||||
|
Include="..\..\Infrastructure\Infrastructure.Repository\Repository.Core\Repository.Core.csproj" />
|
||||||
|
<ProjectReference
|
||||||
|
Include="..\..\Infrastructure\Infrastructure.PasswordHashing\Infrastructure.PasswordHashing.csproj" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
</Project>
|
</Project>
|
||||||
|
|||||||
Reference in New Issue
Block a user