Настроить порт через переменную окружения ASPNETCORE_URLS

This commit is contained in:
2026-04-13 17:52:13 +03:00
parent 879becadfe
commit 380768b110
2 changed files with 4 additions and 3 deletions

View File

@@ -4,7 +4,6 @@ using LazyBear.MCP.Services.Kubernetes;
using LazyBear.MCP.Services.Logging;
using LazyBear.MCP.Services.ToolRegistry;
using LazyBear.MCP.TUI;
using ModelContextProtocol.Server;
var builder = WebApplication.CreateBuilder(args);
@@ -38,4 +37,5 @@ var app = builder.Build();
app.MapMcp();
app.Run("http://localhost:5000");
var urls = Environment.GetEnvironmentVariable("ASPNETCORE_URLS") ?? "http://localhost:5000";
app.Run(urls);

View File

@@ -7,7 +7,8 @@
"launchBrowser": true,
"applicationUrl": "http://localhost:5079",
"environmentVariables": {
"ASPNETCORE_ENVIRONMENT": "Development"
"ASPNETCORE_ENVIRONMENT": "Development",
"ASPNETCORE_URLS": "http://localhost:5152"
}
}
}