Implemented "roundtrip" status checking. Added node ssl field.

This commit is contained in:
2024-12-13 20:12:56 +01:00
parent 3c88b60e8d
commit d15c5326ed
16 changed files with 872 additions and 7 deletions

View File

@@ -0,0 +1,21 @@
using MoonCore.Attributes;
using MoonCore.Helpers;
using MoonlightServers.Shared.Http.Responses.Admin.Nodes.Sys;
namespace MoonlightServers.Frontend.Services;
[Scoped]
public class NodeService
{
private readonly HttpApiClient HttpApiClient;
public NodeService(HttpApiClient httpApiClient)
{
HttpApiClient = httpApiClient;
}
public async Task<NodeSystemStatusResponse> GetSystemStatus(int nodeId)
{
return await HttpApiClient.GetJson<NodeSystemStatusResponse>($"api/admin/servers/nodes/{nodeId}/system/status");
}
}