diff --git a/TaikoLocalServer/Certificates/cert.pfx b/TaikoLocalServer/Certificates/cert.pfx
index f520411..b703cde 100644
Binary files a/TaikoLocalServer/Certificates/cert.pfx and b/TaikoLocalServer/Certificates/cert.pfx differ
diff --git a/TaikoLocalServer/Certificates/root.pfx b/TaikoLocalServer/Certificates/root.pfx
new file mode 100644
index 0000000..a40e669
Binary files /dev/null and b/TaikoLocalServer/Certificates/root.pfx differ
diff --git a/TaikoLocalServer/Common/Utils/FlagCalculator.cs b/TaikoLocalServer/Common/Utils/FlagCalculator.cs
index 9193d93..6a86db5 100644
--- a/TaikoLocalServer/Common/Utils/FlagCalculator.cs
+++ b/TaikoLocalServer/Common/Utils/FlagCalculator.cs
@@ -116,7 +116,7 @@ public static class FlagCalculator
{
if (id >= bitArraySize)
{
- logger.LogWarning("Id out of range!");
+ logger.LogWarning("Id {Id} out of range!", id);
continue;
}
bitSet.Set((int)id, true);
diff --git a/TaikoLocalServer/Program.cs b/TaikoLocalServer/Program.cs
index e8bfad7..67dd292 100644
--- a/TaikoLocalServer/Program.cs
+++ b/TaikoLocalServer/Program.cs
@@ -23,11 +23,8 @@ try
// Manually enable tls 1.0
builder.WebHost.UseKestrel(kestrelOptions =>
{
- kestrelOptions.ConfigureHttpsDefaults(httpsOptions =>
- {
- httpsOptions.SslProtocols =
- SslProtocols.Tls | SslProtocols.Tls11 | SslProtocols.Tls12 | SslProtocols.Tls13;
- });
+ kestrelOptions.ConfigureHttpsDefaults(options =>
+ options.SslProtocols = SslProtocols.Tls | SslProtocols.Tls11 | SslProtocols.Tls12 | SslProtocols.Tls13);
});
builder.Host.UseSerilog((context, configuration) =>
diff --git a/TaikoLocalServer/TaikoLocalServer.csproj b/TaikoLocalServer/TaikoLocalServer.csproj
index 55f1417..e0a0423 100644
--- a/TaikoLocalServer/TaikoLocalServer.csproj
+++ b/TaikoLocalServer/TaikoLocalServer.csproj
@@ -47,6 +47,9 @@
PreserveNewest
+
+ PreserveNewest
+
diff --git a/TaikoLocalServer/appsettings.json b/TaikoLocalServer/appsettings.json
index 13b11b2..239dc28 100644
--- a/TaikoLocalServer/appsettings.json
+++ b/TaikoLocalServer/appsettings.json
@@ -36,8 +36,20 @@
"Kestrel": {
"Endpoints": {
- "Server": {
+ "BaseServer": {
"Url": "http://0.0.0.0:5000"
+ },
+ "AmAuthServer": {
+ "Url": "http://0.0.0.0:80"
+ },
+ "MuchaServer": {
+ "Url": "https://0.0.0.0:10122"
+ },
+ "GameServer1": {
+ "Url": "https://0.0.0.0:54430"
+ },
+ "GameServer2": {
+ "Url": "https://0.0.0.0:54431"
}
},
"Certificates": {
diff --git a/TaikoWebUI/Program.cs b/TaikoWebUI/Program.cs
index 7821a3d..75baef5 100644
--- a/TaikoWebUI/Program.cs
+++ b/TaikoWebUI/Program.cs
@@ -7,7 +7,7 @@ builder.RootComponents.Add("head::after");
builder.Services.AddSingleton(sp => new HttpClient
{
- BaseAddress = new Uri(builder.Configuration.GetValue("BaseUrl"))
+ BaseAddress = new Uri(builder.HostEnvironment.BaseAddress)
});
builder.Services.AddMudServices();
builder.Services.AddSingleton();
@@ -15,10 +15,6 @@ builder.Services.AddSingleton();
var host = builder.Build();
var gameDataService = host.Services.GetRequiredService();
-#if DEBUG
-await gameDataService.InitializeAsync(builder.Configuration.GetValue("DataBaseUrl"));
-#else
-await gameDataService.InitializeAsync(builder.Configuration.GetValue("BaseUrl"));
-#endif
+await gameDataService.InitializeAsync(builder.HostEnvironment.BaseAddress);
await host.RunAsync();
\ No newline at end of file
diff --git a/TaikoWebUI/Services/GameDataService.cs b/TaikoWebUI/Services/GameDataService.cs
index c72f86b..977fe54 100644
--- a/TaikoWebUI/Services/GameDataService.cs
+++ b/TaikoWebUI/Services/GameDataService.cs
@@ -30,6 +30,7 @@ public class GameDataService : IGameDataService
public async Task InitializeAsync(string dataBaseUrl)
{
+ dataBaseUrl = dataBaseUrl.TrimEnd('/');
var musicInfo = await GetData(dataBaseUrl, Constants.MUSIC_INFO_BASE_NAME);
var wordList = await GetData(dataBaseUrl, Constants.WORD_LIST_BASE_NAME);
var musicOrder = await GetData(dataBaseUrl, Constants.MUSIC_ORDER_BASE_NAME);
diff --git a/TaikoWebUI/TaikoWebUI.csproj b/TaikoWebUI/TaikoWebUI.csproj
index fcf3b46..b39c692 100644
--- a/TaikoWebUI/TaikoWebUI.csproj
+++ b/TaikoWebUI/TaikoWebUI.csproj
@@ -20,9 +20,6 @@
-
- PreserveNewest
-
PreserveNewest
@@ -32,6 +29,18 @@
PreserveNewest
+
+ PreserveNewest
+
+
+ PreserveNewest
+
+
+ PreserveNewest
+
+
+ PreserveNewest
+
diff --git a/TaikoWebUI/wwwroot/appsettings.Development.json b/TaikoWebUI/wwwroot/appsettings.Development.json
deleted file mode 100644
index ce35693..0000000
--- a/TaikoWebUI/wwwroot/appsettings.Development.json
+++ /dev/null
@@ -1,3 +0,0 @@
-{
- "DataBaseUrl": "http://localhost:5000"
-}
\ No newline at end of file
diff --git a/TaikoWebUI/wwwroot/appsettings.json b/TaikoWebUI/wwwroot/appsettings.json
deleted file mode 100644
index e575e49..0000000
--- a/TaikoWebUI/wwwroot/appsettings.json
+++ /dev/null
@@ -1,3 +0,0 @@
-{
- "BaseUrl": "http://localhost:5000"
-}
\ No newline at end of file