AbdulQASDET
AbdulQASDET

Reputation: 73

API Swagger URL is not loading at all through .NET aspire 9.0

I've added Aspire 9.0 project to spin API swagger and SQL Server container.

I'm able to spin SQL Server container, but not API Swagger URL.

I've added project references of both API and database projects to the app host project.

App host project > Program.cs file contains this code:

var builder = DistributedApplication.CreateBuilder(args);

//Database
var sqlServer = builder.AddSqlServer("sql").AddDatabase("db");
builder.AddSqlProject("sqlproject").WithDacpac("O.WP.Database.dacpac").WithReference(sqlServer);

//Api
builder.AddProject<Projects.O_WP_PIT_ACT_API>("apiservice").WithReference(sqlServer);

builder.Build().Run();

Upvotes: 0

Views: 56

Answers (0)

Related Questions