App login is working
This commit is contained in:
@@ -4,6 +4,7 @@ using Microsoft.IdentityModel.Tokens;
|
||||
using System.IdentityModel.Tokens.Jwt;
|
||||
using System.Reflection;
|
||||
using System.Text;
|
||||
using DiunaBI.API.Services;
|
||||
using DiunaBI.Infrastructure.Data;
|
||||
using DiunaBI.Infrastructure.Services;
|
||||
using Google.Apis.Sheets.v4;
|
||||
@@ -74,6 +75,9 @@ builder.Services.AddAuthentication(options =>
|
||||
};
|
||||
});
|
||||
|
||||
builder.Services.AddScoped<GoogleAuthService>();
|
||||
builder.Services.AddScoped<JwtTokenService>();
|
||||
|
||||
// Google Sheets dependencies
|
||||
Console.WriteLine("Adding Google Sheets dependencies...");
|
||||
builder.Services.AddSingleton<GoogleSheetsHelper>();
|
||||
@@ -159,6 +163,9 @@ app.UseAuthorization();
|
||||
|
||||
app.MapControllers();
|
||||
|
||||
app.MapGet("/health", () => Results.Ok(new { status = "OK", timestamp = DateTime.UtcNow }))
|
||||
.AllowAnonymous();
|
||||
|
||||
app.Run();
|
||||
|
||||
if (app.Environment.IsProduction())
|
||||
|
||||
Reference in New Issue
Block a user