mirror of
https://github.com/esiur/esiur-dotnet.git
synced 2025-06-27 13:33:13 +00:00
ASP.Net
This commit is contained in:
@ -14,10 +14,10 @@ var builder = WebApplication.CreateBuilder(args);
|
||||
|
||||
// Add services to the container.
|
||||
|
||||
//builder.Services.AddControllers();
|
||||
builder.Services.AddControllers();
|
||||
// Learn more about configuring Swagger/OpenAPI at https://aka.ms/aspnetcore/swashbuckle
|
||||
//builder.Services.AddEndpointsApiExplorer();
|
||||
//builder.Services.AddSwaggerGen();
|
||||
builder.Services.AddEndpointsApiExplorer();
|
||||
builder.Services.AddSwaggerGen();
|
||||
|
||||
builder.WebHost.UseUrls("http://localhost:8080");
|
||||
|
||||
@ -32,17 +32,17 @@ app.UseWebSockets(webSocketOptions);
|
||||
|
||||
|
||||
// Configure the HTTP request pipeline.
|
||||
//if (app.Environment.IsDevelopment())
|
||||
//{
|
||||
// app.UseSwagger();
|
||||
// app.UseSwaggerUI();
|
||||
//}
|
||||
if (app.Environment.IsDevelopment())
|
||||
{
|
||||
app.UseSwagger();
|
||||
app.UseSwaggerUI();
|
||||
}
|
||||
|
||||
//app.UseHttpsRedirection();
|
||||
app.UseHttpsRedirection();
|
||||
|
||||
//app.UseAuthorization();
|
||||
app.UseAuthorization();
|
||||
|
||||
//app.MapControllers();
|
||||
app.MapControllers();
|
||||
|
||||
|
||||
await Warehouse.Put("sys", new MemoryStore());
|
||||
|
Reference in New Issue
Block a user