Compare commits

..

No commits in common. "025999ab59b9fb87e2428e0b7d625af4da003c67" and "ad32b00dd03d1506c67ebf9c6ca4da9b64c56f20" have entirely different histories.

21 changed files with 81 additions and 110 deletions

View File

@ -1,11 +0,0 @@
FROM mcr.microsoft.com/devcontainers/anaconda:1-3
# Copy environment.yml (if found) to a temp location so we update the environment. Also
# copy "noop.txt" so the COPY instruction does not fail if no environment.yml exists.
COPY environment.yml* .devcontainer/noop.txt /tmp/conda-tmp/
RUN if [ -f "/tmp/conda-tmp/environment.yml" ]; then umask 0002 && /opt/conda/bin/conda env update -n base -f /tmp/conda-tmp/environment.yml; fi \
&& rm -rf /tmp/conda-tmp
# [Optional] Uncomment this section to install additional OS packages.
# RUN apt-get update && export DEBIAN_FRONTEND=noninteractive \
# && apt-get -y install --no-install-recommends <your-package-list-here>

View File

@ -1,30 +0,0 @@
// For format details, see https://aka.ms/devcontainer.json. For config options, see the
// README at: https://github.com/devcontainers/templates/tree/main/src/anaconda
{
"name": "Anaconda (Python 3)",
"build": {
"context": "..",
"dockerfile": "Dockerfile"
},
"customizations": {
"vscode": {
"extensions": [
"ms-dotnettools.vscode-dotnet-runtime",
"svelte.svelte-vscode",
"syler.sass-indented",
"dbaeumer.vscode-eslint",
"ms-dotnettools.csharp"
],
"settings": {
"python.defaultInterpreterPath": "/opt/conda/bin/python",
"dotnet.dotnetPath": "/opt/conda/lib/dotnet/",
"omnisharp.dotNetCliPaths": [
"/opt/conda/lib/dotnet/dotnet"
]
}
}
},
"postCreateCommand": "bash -i -c 'conda init'"
}

View File

@ -1,3 +0,0 @@
This file copied into the container along with environment.yml* from the parent
folder. This file is included to prevents the Dockerfile COPY instruction from
failing if no environment.yml is found.

3
.gitmodules vendored
View File

@ -0,0 +1,3 @@
[submodule "SimpleLogger"]
path = SimpleLogger
url = https://sys.reslate.net/git/ydeng/SimpleLogger.git

View File

@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<TargetFramework>net7.0</TargetFramework>
<IsPackable>false</IsPackable>
</PropertyGroup>
@ -17,6 +17,7 @@
<ItemGroup>
<ProjectReference Include="..\..\GameServiceWarden\GameServiceWarden.Core\GameServiceWarden.Core.csproj" />
<ProjectReference Include="..\..\GameServiceWarden\GameServiceWarden.ModuleFramework\GameServiceWarden.ModuleFramework.csproj" />
<ProjectReference Include="..\..\SimpleLogger\SimpleLogger.csproj" />
</ItemGroup>
</Project>

View File

@ -4,6 +4,7 @@ using GameServiceWarden.Core.Module;
using GameServiceWarden.ModuleFramework;
using Xunit;
using Xunit.Abstractions;
using SimpleLogger;
namespace GameServiceWarden.Core.Tests.Modules
{

View File

@ -1,6 +1,7 @@
using System.Collections.Generic;
using System.IO;
using GameServiceWarden.Core.Module;
using SimpleLogger;
using GameServiceWarden.ModuleFramework;
using Xunit;
using Xunit.Abstractions;

View File

@ -1,4 +1,5 @@
using System;
using SimpleLogger;
using GameServiceWarden.Core.UI;
using Xunit;
using Xunit.Abstractions;

View File

@ -1,4 +1,5 @@
using System;
using SimpleLogger;
using Xunit.Abstractions;
namespace GameServiceWarden.Core.Tests

View File

@ -0,0 +1,22 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.0.31903.59
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GameServiceWarden.Core.Tests", "GameServiceWarden.Core.Tests\GameServiceWarden.Core.Tests.csproj", "{59D37458-41F3-478C-BDE6-CF33EC667701}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{59D37458-41F3-478C-BDE6-CF33EC667701}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{59D37458-41F3-478C-BDE6-CF33EC667701}.Debug|Any CPU.Build.0 = Debug|Any CPU
{59D37458-41F3-478C-BDE6-CF33EC667701}.Release|Any CPU.ActiveCfg = Release|Any CPU
{59D37458-41F3-478C-BDE6-CF33EC667701}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
EndGlobal

View File

@ -3,11 +3,12 @@
<ItemGroup>
<ProjectReference Include="..\GameServiceWarden.ModuleFramework\GameServiceWarden.ModuleFramework.csproj" />
<ProjectReference Include="..\GameServiceWarden.InteractionAPI\GameServiceWarden.InteractionAPI.csproj" />
<ProjectReference Include="..\..\SimpleLogger\SimpleLogger.csproj" />
</ItemGroup>
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net8.0</TargetFramework>
<TargetFramework>net7.0</TargetFramework>
</PropertyGroup>
</Project>

View File

@ -10,6 +10,7 @@ using System.Text;
using System.Threading;
using System.Threading.Tasks;
using GameServiceWarden.Core.Module.Exceptions;
using SimpleLogger;
using GameServiceWarden.ModuleFramework;
using System.Net.Sockets;

View File

@ -3,6 +3,7 @@ using System.Text.Json;
using GameServiceWarden.InteractionAPI;
using GameServiceWarden.InteractionAPI.Communicable.Requests;
using GameServiceWarden.Core.Module;
using SimpleLogger;
namespace GameServiceWarden.Core.UI
{

View File

@ -10,6 +10,7 @@ using System.Threading.Tasks;
using GameServiceWarden.InteractionAPI;
using GameServiceWarden.InteractionAPI.Communicable.Requests;
using GameServiceWarden.InteractionAPI.Communicable.Responses;
using SimpleLogger;
namespace GameServiceWarden.Core.UI
{

View File

@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<TargetFramework>net7.0</TargetFramework>
</PropertyGroup>
</Project>

View File

@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<TargetFramework>net7.0</TargetFramework>
</PropertyGroup>
</Project>

View File

@ -0,0 +1,34 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.0.31903.59
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GameServiceWarden.Core", "GameServiceWarden.Core\GameServiceWarden.Core.csproj", "{72FE4FFA-8730-4043-BCE9-794E816542CA}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GameServiceWarden.InteractionAPI", "GameServiceWarden.InteractionAPI\GameServiceWarden.InteractionAPI.csproj", "{A254A364-8089-4799-8F45-02E683D59F75}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GameServiceWarden.ModuleFramework", "GameServiceWarden.ModuleFramework\GameServiceWarden.ModuleFramework.csproj", "{23F7A773-D146-4522-8200-BDD60E39B79F}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{72FE4FFA-8730-4043-BCE9-794E816542CA}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{72FE4FFA-8730-4043-BCE9-794E816542CA}.Debug|Any CPU.Build.0 = Debug|Any CPU
{72FE4FFA-8730-4043-BCE9-794E816542CA}.Release|Any CPU.ActiveCfg = Release|Any CPU
{72FE4FFA-8730-4043-BCE9-794E816542CA}.Release|Any CPU.Build.0 = Release|Any CPU
{A254A364-8089-4799-8F45-02E683D59F75}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{A254A364-8089-4799-8F45-02E683D59F75}.Debug|Any CPU.Build.0 = Debug|Any CPU
{A254A364-8089-4799-8F45-02E683D59F75}.Release|Any CPU.ActiveCfg = Release|Any CPU
{A254A364-8089-4799-8F45-02E683D59F75}.Release|Any CPU.Build.0 = Release|Any CPU
{23F7A773-D146-4522-8200-BDD60E39B79F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{23F7A773-D146-4522-8200-BDD60E39B79F}.Debug|Any CPU.Build.0 = Debug|Any CPU
{23F7A773-D146-4522-8200-BDD60E39B79F}.Release|Any CPU.ActiveCfg = Release|Any CPU
{23F7A773-D146-4522-8200-BDD60E39B79F}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
EndGlobal

17
Jenkinsfile vendored
View File

@ -1,21 +1,18 @@
pipeline {
agent {
kubernetes {
cloud 'Reslate Systems'
defaultContainer 'conda'
}
}
agent any
stages {
stage ("Install") {
steps {
sh "conda update conda -y -q"
sh "conda env update -n base --file environment.yml"
sh "conda run -n base dotnet restore gameservicewarden.sln"
sh "mamba env update --file environment.yml"
sh "echo 'mamba activate gameservicewarden' >> ~/.bashrc"
sh "git submodule update --init --recursive"
sh "dotnet restore GameServiceWarden"
sh "dotnet restore GameServiceWarden.Tests"
}
}
stage ("Test") {
steps {
sh "conda run -n base dotnet test --logger xunit --no-restore GameServiceWarden.Tests"
sh "dotnet test --logger xunit --no-restore GameServiceWarden.Tests"
xunit([xUnitDotNet(excludesPattern: '', pattern: 'GameServiceWarden.Tests/*.Tests/TestResults/*.xml', stopProcessingIfError: true)])
}
}

1
SimpleLogger Submodule

@ -0,0 +1 @@
Subproject commit f9931eea4295353befffcf1880ea510cc259e9f2

View File

@ -2,5 +2,4 @@ name: gameservicewarden
channels:
- conda-forge
dependencies:
- dotnet
- icu
- dotnet-sdk=7.0.*

View File

@ -1,50 +0,0 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.0.31903.59
MinimumVisualStudioVersion = 10.0.40219.1
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "GameServiceWarden", "GameServiceWarden", "{10373EAF-A78D-45C0-8F8E-FFA1F1D4DF33}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GameServiceWarden.Core", "GameServiceWarden\GameServiceWarden.Core\GameServiceWarden.Core.csproj", "{3F7158B1-8C80-4529-9B1B-827329F699A7}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GameServiceWarden.InteractionAPI", "GameServiceWarden\GameServiceWarden.InteractionAPI\GameServiceWarden.InteractionAPI.csproj", "{0DF20C89-C55C-401F-A607-A41A6EC6273E}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GameServiceWarden.ModuleFramework", "GameServiceWarden\GameServiceWarden.ModuleFramework\GameServiceWarden.ModuleFramework.csproj", "{26B4678F-A48E-4A81-A304-3179D7C984E8}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "GameServiceWarden.Tests", "GameServiceWarden.Tests", "{103BE93B-FB65-47AC-8741-90823A23A23E}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GameServiceWarden.Core.Tests", "GameServiceWarden.Tests\GameServiceWarden.Core.Tests\GameServiceWarden.Core.Tests.csproj", "{48DD5E4F-1C9F-4642-AF7C-B43E91E83BB2}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{3F7158B1-8C80-4529-9B1B-827329F699A7}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{3F7158B1-8C80-4529-9B1B-827329F699A7}.Debug|Any CPU.Build.0 = Debug|Any CPU
{3F7158B1-8C80-4529-9B1B-827329F699A7}.Release|Any CPU.ActiveCfg = Release|Any CPU
{3F7158B1-8C80-4529-9B1B-827329F699A7}.Release|Any CPU.Build.0 = Release|Any CPU
{0DF20C89-C55C-401F-A607-A41A6EC6273E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{0DF20C89-C55C-401F-A607-A41A6EC6273E}.Debug|Any CPU.Build.0 = Debug|Any CPU
{0DF20C89-C55C-401F-A607-A41A6EC6273E}.Release|Any CPU.ActiveCfg = Release|Any CPU
{0DF20C89-C55C-401F-A607-A41A6EC6273E}.Release|Any CPU.Build.0 = Release|Any CPU
{26B4678F-A48E-4A81-A304-3179D7C984E8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{26B4678F-A48E-4A81-A304-3179D7C984E8}.Debug|Any CPU.Build.0 = Debug|Any CPU
{26B4678F-A48E-4A81-A304-3179D7C984E8}.Release|Any CPU.ActiveCfg = Release|Any CPU
{26B4678F-A48E-4A81-A304-3179D7C984E8}.Release|Any CPU.Build.0 = Release|Any CPU
{48DD5E4F-1C9F-4642-AF7C-B43E91E83BB2}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{48DD5E4F-1C9F-4642-AF7C-B43E91E83BB2}.Debug|Any CPU.Build.0 = Debug|Any CPU
{48DD5E4F-1C9F-4642-AF7C-B43E91E83BB2}.Release|Any CPU.ActiveCfg = Release|Any CPU
{48DD5E4F-1C9F-4642-AF7C-B43E91E83BB2}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(NestedProjects) = preSolution
{3F7158B1-8C80-4529-9B1B-827329F699A7} = {10373EAF-A78D-45C0-8F8E-FFA1F1D4DF33}
{0DF20C89-C55C-401F-A607-A41A6EC6273E} = {10373EAF-A78D-45C0-8F8E-FFA1F1D4DF33}
{26B4678F-A48E-4A81-A304-3179D7C984E8} = {10373EAF-A78D-45C0-8F8E-FFA1F1D4DF33}
{48DD5E4F-1C9F-4642-AF7C-B43E91E83BB2} = {103BE93B-FB65-47AC-8741-90823A23A23E}
EndGlobalSection
EndGlobal