diff --git a/src/.dockerignore b/src/.dockerignore deleted file mode 100644 index 4d72b4f..0000000 --- a/src/.dockerignore +++ /dev/null @@ -1,30 +0,0 @@ -**/.classpath -**/.dockerignore -**/.env -**/.git -**/.gitignore -**/.project -**/.settings -**/.toolstarget -**/.vs -**/.vscode -**/*.*proj.user -**/*.dbmdl -**/*.jfm -**/azds.yaml -**/bin -**/charts -**/docker-compose* -**/Dockerfile* -**/node_modules -**/npm-debug.log -**/obj -**/secrets.dev.yaml -**/values.dev.yaml -LICENSE -README.md -!**/.gitignore -!.git/HEAD -!.git/config -!.git/packed-refs -!.git/refs/heads/** \ No newline at end of file diff --git a/src/Sphagnum.DebugClient/Controllers/TestController.cs b/src/Sphagnum.DebugClient/Controllers/TestController.cs deleted file mode 100644 index bb2cc62..0000000 --- a/src/Sphagnum.DebugClient/Controllers/TestController.cs +++ /dev/null @@ -1,42 +0,0 @@ -using Microsoft.AspNetCore.Mvc; -using Sphagnum.Common.Contracts.Messaging; -using Sphagnum.Common.Contracts.Messaging.Messages; - -namespace Sphagnum.DebugClient.Controllers -{ - [ApiController] - [Route("[controller]/[action]")] - public class TestController : ControllerBase - { - private readonly IMessagingClient _connection; - private static readonly Task? rec; - - public TestController(IMessagingClient connection) - { - _connection = connection; - } - - [HttpGet] - public string test() - { - return "Ok!"; - } - - - [HttpGet] - public async Task Send(int size) - { - var payload1 = new byte[size]; - var payload2 = new byte[size]; - - for (int i = 0; i < size; i++) - { - payload1[i] = 1; - payload2[i] = 2; - } - var t1 = _connection.Publish(new OutgoingMessage("test", payload1)).AsTask(); - var t2 = _connection.Publish(new OutgoingMessage("test", payload2)).AsTask(); - await Task.WhenAll(t1, t2); - } - } -} diff --git a/src/Sphagnum.DebugClient/Dockerfile b/src/Sphagnum.DebugClient/Dockerfile deleted file mode 100644 index 66a1437..0000000 --- a/src/Sphagnum.DebugClient/Dockerfile +++ /dev/null @@ -1,27 +0,0 @@ -#See https://aka.ms/customizecontainer to learn how to customize your debug container and how Visual Studio uses this Dockerfile to build your images for faster debugging. - -FROM mcr.microsoft.com/dotnet/aspnet:8.0 AS base -USER app -WORKDIR /app -EXPOSE 8080 - -FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build -ARG BUILD_CONFIGURATION=Release -WORKDIR /src -COPY ["Sphagnum.DebugClient/Sphagnum.DebugClient.csproj", "Sphagnum.DebugClient/"] -COPY ["Sphagnum.Client/Sphagnum.Client.csproj", "Sphagnum.Client/"] -COPY ["Sphagnum.Common/Sphagnum.Common.csproj", "Sphagnum.Common/"] -COPY ["Sphagnum.Common.Contracts/Sphagnum.Common.Contracts.csproj", "Sphagnum.Common.Contracts/"] -RUN dotnet restore "./Sphagnum.DebugClient/./Sphagnum.DebugClient.csproj" -COPY . . -WORKDIR "/src/Sphagnum.DebugClient" -RUN dotnet build "./Sphagnum.DebugClient.csproj" -c $BUILD_CONFIGURATION -o /app/build - -FROM build AS publish -ARG BUILD_CONFIGURATION=Release -RUN dotnet publish "./Sphagnum.DebugClient.csproj" -c $BUILD_CONFIGURATION -o /app/publish /p:UseAppHost=false - -FROM base AS final -WORKDIR /app -COPY --from=publish /app/publish . -ENTRYPOINT ["dotnet", "Sphagnum.DebugClient.dll"] \ No newline at end of file diff --git a/src/Sphagnum.DebugClient/Program.cs b/src/Sphagnum.DebugClient/Program.cs deleted file mode 100644 index ccc6299..0000000 --- a/src/Sphagnum.DebugClient/Program.cs +++ /dev/null @@ -1,26 +0,0 @@ -using Sphagnum.Client; -using Sphagnum.Common.Contracts.Login; -using Sphagnum.Common.Contracts.Messaging; - -var builder = WebApplication.CreateBuilder(args); - -builder.Services.AddControllers(); -builder.Services.AddEndpointsApiExplorer(); -builder.Services.AddSwaggerGen(); -builder.Services.AddSingleton(new ConnectionFactory() -{ - UserRights = UserRights.All, - Login = "root", - Password = "root", - Hostname = "test_server", - Port = 8081, -}); -builder.Services.AddSingleton(); -var app = builder.Build(); - -app.UseSwagger(); -app.UseSwaggerUI(); - -app.MapControllers(); - -app.Run(); diff --git a/src/Sphagnum.DebugClient/Sphagnum.DebugClient.csproj b/src/Sphagnum.DebugClient/Sphagnum.DebugClient.csproj deleted file mode 100644 index 4e338e0..0000000 --- a/src/Sphagnum.DebugClient/Sphagnum.DebugClient.csproj +++ /dev/null @@ -1,21 +0,0 @@ - - - - net8.0 - enable - enable - true - Linux - ..\docker-compose.dcproj - - - - - - - - - - - - diff --git a/src/Sphagnum.DebugClient/appsettings.Development.json b/src/Sphagnum.DebugClient/appsettings.Development.json deleted file mode 100644 index ff66ba6..0000000 --- a/src/Sphagnum.DebugClient/appsettings.Development.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "Logging": { - "LogLevel": { - "Default": "Information", - "Microsoft.AspNetCore": "Warning" - } - } -} diff --git a/src/Sphagnum.DebugClient/appsettings.json b/src/Sphagnum.DebugClient/appsettings.json deleted file mode 100644 index 4d56694..0000000 --- a/src/Sphagnum.DebugClient/appsettings.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "Logging": { - "LogLevel": { - "Default": "Information", - "Microsoft.AspNetCore": "Warning" - } - }, - "AllowedHosts": "*" -} diff --git a/src/Sphagnum.DebugService/Dockerfile b/src/Sphagnum.DebugService/Dockerfile deleted file mode 100644 index 195cf2d..0000000 --- a/src/Sphagnum.DebugService/Dockerfile +++ /dev/null @@ -1,27 +0,0 @@ -#See https://aka.ms/customizecontainer to learn how to customize your debug container and how Visual Studio uses this Dockerfile to build your images for faster debugging. - -FROM mcr.microsoft.com/dotnet/aspnet:8.0 AS base -USER app -WORKDIR /app -EXPOSE 8080 - -FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build -ARG BUILD_CONFIGURATION=Release -WORKDIR /src -COPY ["Sphagnum.DebugService/Sphagnum.DebugService.csproj", "Sphagnum.DebugService/"] -COPY ["Sphagnum.Server/Sphagnum.Server.csproj", "Sphagnum.Server/"] -COPY ["Sphagnum.Common/Sphagnum.Common.csproj", "Sphagnum.Common/"] -COPY ["Sphagnum.Common.Contracts/Sphagnum.Common.Contracts.csproj", "Sphagnum.Common.Contracts/"] -RUN dotnet restore "./Sphagnum.DebugService/./Sphagnum.DebugService.csproj" -COPY . . -WORKDIR "/src/Sphagnum.DebugService" -RUN dotnet build "./Sphagnum.DebugService.csproj" -c $BUILD_CONFIGURATION -o /app/build - -FROM build AS publish -ARG BUILD_CONFIGURATION=Release -RUN dotnet publish "./Sphagnum.DebugService.csproj" -c $BUILD_CONFIGURATION -o /app/publish /p:UseAppHost=false - -FROM base AS final -WORKDIR /app -COPY --from=publish /app/publish . -ENTRYPOINT ["dotnet", "Sphagnum.DebugService.dll"] \ No newline at end of file diff --git a/src/Sphagnum.DebugService/Program.cs b/src/Sphagnum.DebugService/Program.cs deleted file mode 100644 index ba6e133..0000000 --- a/src/Sphagnum.DebugService/Program.cs +++ /dev/null @@ -1,12 +0,0 @@ -using Sphagnum.Common.Contracts.Login; -using Sphagnum.Server; - -var builder = WebApplication.CreateBuilder(args); -builder.Services.AddControllers(); -builder.Services.AddSingleton(); -builder.Services.AddHostedService(); - -var app = builder.Build(); -app.MapControllers(); - -app.Run(); diff --git a/src/Sphagnum.DebugService/Sphagnum.DebugService.csproj b/src/Sphagnum.DebugService/Sphagnum.DebugService.csproj deleted file mode 100644 index 5856a8c..0000000 --- a/src/Sphagnum.DebugService/Sphagnum.DebugService.csproj +++ /dev/null @@ -1,21 +0,0 @@ - - - - net8.0 - enable - enable - true - Linux - ..\..\src - ..\docker-compose.dcproj - - - - - - - - - - - diff --git a/src/Sphagnum.DebugService/appsettings.Development.json b/src/Sphagnum.DebugService/appsettings.Development.json deleted file mode 100644 index ff66ba6..0000000 --- a/src/Sphagnum.DebugService/appsettings.Development.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "Logging": { - "LogLevel": { - "Default": "Information", - "Microsoft.AspNetCore": "Warning" - } - } -} diff --git a/src/Sphagnum.DebugService/appsettings.json b/src/Sphagnum.DebugService/appsettings.json deleted file mode 100644 index 4d56694..0000000 --- a/src/Sphagnum.DebugService/appsettings.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "Logging": { - "LogLevel": { - "Default": "Information", - "Microsoft.AspNetCore": "Warning" - } - }, - "AllowedHosts": "*" -} diff --git a/src/docker-compose.dcproj b/src/docker-compose.dcproj deleted file mode 100644 index 1bcaa56..0000000 --- a/src/docker-compose.dcproj +++ /dev/null @@ -1,19 +0,0 @@ - - - - 2.1 - Linux - False - 832db06c-c0f5-4608-b94f-86fde003c420 - LaunchBrowser - {Scheme}://localhost:{ServicePort}/swagger - sphagnum.debugclient - - - - docker-compose.yml - - - - - \ No newline at end of file diff --git a/src/docker-compose.override.yml b/src/docker-compose.override.yml deleted file mode 100644 index 35af6b1..0000000 --- a/src/docker-compose.override.yml +++ /dev/null @@ -1,2 +0,0 @@ -version: '3.4' - diff --git a/src/docker-compose.yml b/src/docker-compose.yml deleted file mode 100644 index d25d99a..0000000 --- a/src/docker-compose.yml +++ /dev/null @@ -1,22 +0,0 @@ -version: '3.4' - -services: - sphagnum.debugclient: - depends_on: - - sphagnum.debugservice - image: sphagnumdebugclient - ports: - - 5000:8080 - build: - context: . - dockerfile: Sphagnum.DebugClient/Dockerfile - - sphagnum.debugservice: - hostname: test_server - image: sphagnumdebugservice - ports: - - 5001:8080 - build: - context: . - dockerfile: Sphagnum.DebugService/Dockerfile - diff --git a/src/launchSettings.json b/src/launchSettings.json deleted file mode 100644 index 54a5fb7..0000000 --- a/src/launchSettings.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "profiles": { - "Docker Compose": { - "commandName": "DockerCompose", - "commandVersion": "1.0", - "serviceActions": { - "sphagnum.debugclient": "StartDebugging", - "sphagnum.debugservice": "StartDebugging" - } - } - } -} \ No newline at end of file