SPA checks for its dependences on healthcheck
This commit is contained in:
parent
0c205fc8bd
commit
80bac99f63
@ -9,6 +9,7 @@ namespace eShopConContainers.WebSPA
|
||||
{
|
||||
var host = new WebHostBuilder()
|
||||
.UseKestrel()
|
||||
.UseHealthChecks("/hc")
|
||||
.UseContentRoot(Directory.GetCurrentDirectory())
|
||||
.UseIISIntegration()
|
||||
.UseStartup<Startup>()
|
||||
|
@ -43,7 +43,10 @@ namespace eShopConContainers.WebSPA
|
||||
{
|
||||
services.AddHealthChecks(checks =>
|
||||
{
|
||||
checks.AddValueTaskCheck("HTTP Endpoint", () => new ValueTask<IHealthCheckResult>(HealthCheckResult.Healthy("Ok")));
|
||||
checks.AddUrlCheck(Configuration["CatalogUrl"]);
|
||||
checks.AddUrlCheck(Configuration["OrderingUrl"]);
|
||||
checks.AddUrlCheck(Configuration["BasketUrl"]);
|
||||
checks.AddUrlCheck(Configuration["IdentityUrl"]);
|
||||
});
|
||||
|
||||
services.Configure<AppSettings>(Configuration);
|
||||
|
Loading…
x
Reference in New Issue
Block a user