Recreated project with project template
This commit is contained in:
@@ -1,8 +0,0 @@
|
||||
namespace MoonlightServers.Shared.Enums;
|
||||
|
||||
public enum BackupState
|
||||
{
|
||||
Creating = 0,
|
||||
Failed = 1,
|
||||
Created = 2
|
||||
}
|
||||
@@ -1,9 +0,0 @@
|
||||
namespace MoonlightServers.Shared.Enums;
|
||||
|
||||
public enum StarVariableType
|
||||
{
|
||||
Text = 0,
|
||||
Number = 1,
|
||||
Toggle = 2,
|
||||
Select = 3
|
||||
}
|
||||
@@ -1,14 +0,0 @@
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace MoonlightServers.Shared.Http.Requests.Admin.Allocations;
|
||||
|
||||
public class CreateAllocationRequest
|
||||
{
|
||||
[Required(ErrorMessage = "You need to provide an ip address")]
|
||||
[RegularExpression("^(?:[0-9]{1,3}\\.){3}[0-9]{1,3}$", ErrorMessage = "You need tp provide a valid ip address")]
|
||||
public string IpAddress { get; set; } = "0.0.0.0";
|
||||
|
||||
[Required(ErrorMessage = "You need to provgide a port")]
|
||||
[Range(1, 65535 , ErrorMessage = "You need to provide a valid port")]
|
||||
public int Port { get; set; }
|
||||
}
|
||||
@@ -1,14 +0,0 @@
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace MoonlightServers.Shared.Http.Requests.Admin.Allocations;
|
||||
|
||||
public class UpdateAllocationRequest
|
||||
{
|
||||
[Required(ErrorMessage = "You need to provide an ip address")]
|
||||
[RegularExpression("^(?:[0-9]{1,3}\\.){3}[0-9]{1,3}$", ErrorMessage = "You need tp provide a valid ip address")]
|
||||
public string IpAddress { get; set; } = "0.0.0.0";
|
||||
|
||||
[Required(ErrorMessage = "You need to provgide a port")]
|
||||
[Range(1, 65535 , ErrorMessage = "You need to provide a valid port")]
|
||||
public int Port { get; set; }
|
||||
}
|
||||
@@ -1,17 +0,0 @@
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace MoonlightServers.Shared.Http.Requests.Admin.Nodes;
|
||||
|
||||
public class CreateNodeRequest
|
||||
{
|
||||
[Required(ErrorMessage = "You need to provide a name")]
|
||||
public string Name { get; set; }
|
||||
|
||||
[Required(ErrorMessage = "You need to provide a fqdn")]
|
||||
public string Fqdn { get; set; }
|
||||
|
||||
[Range(1, 65535, ErrorMessage = "You need to provide a valid port")]
|
||||
public int ApiPort { get; set; } = 8080;
|
||||
|
||||
public bool SslEnabled { get; set; } = false;
|
||||
}
|
||||
@@ -1,17 +0,0 @@
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace MoonlightServers.Shared.Http.Requests.Admin.Nodes;
|
||||
|
||||
public class UpdateNodeRequest
|
||||
{
|
||||
[Required(ErrorMessage = "You need to provide a name")]
|
||||
public string Name { get; set; }
|
||||
|
||||
[Required(ErrorMessage = "You need to provide a fqdn")]
|
||||
public string Fqdn { get; set; }
|
||||
|
||||
[Range(1, 65535, ErrorMessage = "You need to provide a valid port")]
|
||||
public int ApiPort { get; set; } = 8080;
|
||||
|
||||
public bool SslEnabled { get; set; } = false;
|
||||
}
|
||||
@@ -1,8 +0,0 @@
|
||||
namespace MoonlightServers.Shared.Http.Responses.Admin.Allocations;
|
||||
|
||||
public class DetailAllocationResponse
|
||||
{
|
||||
public int Id { get; set; }
|
||||
public string IpAddress { get; set; } = "0.0.0.0";
|
||||
public int Port { get; set; }
|
||||
}
|
||||
@@ -1,11 +0,0 @@
|
||||
namespace MoonlightServers.Shared.Http.Responses.Admin.Nodes;
|
||||
|
||||
public class DetailNodeResponse
|
||||
{
|
||||
public int Id { get; set; }
|
||||
|
||||
public string Name { get; set; }
|
||||
public string Fqdn { get; set; }
|
||||
public int ApiPort { get; set; }
|
||||
public bool SslEnabled { get; set; }
|
||||
}
|
||||
@@ -1,22 +0,0 @@
|
||||
namespace MoonlightServers.Shared.Http.Responses.Admin.Nodes;
|
||||
|
||||
public class StatusNodeResponse
|
||||
{
|
||||
public string CpuModel { get; set; }
|
||||
public double[] CpuUsage { get; set; }
|
||||
public TimeSpan Uptime { get; set; }
|
||||
|
||||
public ulong MemoryTotal { get; set; }
|
||||
public ulong MemoryFree { get; set; }
|
||||
public ulong MemoryAvailable { get; set; }
|
||||
public ulong MemoryCached { get; set; }
|
||||
|
||||
public ulong SwapTotal { get; set; }
|
||||
public ulong SwapFree { get; set; }
|
||||
|
||||
public ulong DiskTotal { get; set; }
|
||||
public ulong DiskFree { get; set; }
|
||||
|
||||
public ulong DiskTotalInodes { get; set; }
|
||||
public ulong DiskFreeInodes { get; set; }
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
namespace MoonlightServers.Shared.Http.Responses;
|
||||
|
||||
public class ExampleResponse
|
||||
{
|
||||
public int Number { get; set; }
|
||||
}
|
||||
@@ -7,7 +7,7 @@
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Folder Include="Models\" />
|
||||
<Folder Include="Http\Requests\"/>
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
||||
Reference in New Issue
Block a user