Changeset 8e32210


Ignore:
Timestamp:
10/23/25 15:32:17 (11 months ago)
Author:
GitHub <noreply@…>
Branches:
master
Children:
5eb7847
Parents:
c11d3a3 (diff), cb8e531 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
git-author:
Stefan Saveski <76560180+stefansaveski@…> (10/23/25 15:32:17)
git-committer:
GitHub <noreply@…> (10/23/25 15:32:17)
Message:

Merge pull request #2 from stefansaveski/feature/auth-system-integration

Feature/auth system integration

Location:
iknow-api
Files:
11 added
1 deleted
3 edited

Legend:

Unmodified
Added
Removed
  • iknow-api/Program.cs

    rc11d3a3 r8e32210  
     1using Microsoft.EntityFrameworkCore;
     2using iknow_api.Core.Data;
     3using iknow_api.Services;
     4using iknow_api.Repositories;
     5
    16var builder = WebApplication.CreateBuilder(args);
    27
    38// Add services to the container.
     9builder.Services.AddControllers();
     10builder.Services.AddOpenApi();
    411
    5 builder.Services.AddControllers();
    6 // Learn more about configuring OpenAPI at https://aka.ms/aspnet/openapi
    7 builder.Services.AddOpenApi();
     12// Register DbContext
     13builder.Services.AddDbContext<AppDbContext>(options =>
     14    options.UseNpgsql(builder.Configuration.GetConnectionString("DefaultConnection")));
     15
     16// Register your services
     17builder.Services.AddScoped<IAuthService, AuthService>();
     18builder.Services.AddScoped<IUserRepository, UserRepository>(); // You'll need to add the UserRepository implementation
    819
    920var app = builder.Build();
     
    1627
    1728app.UseHttpsRedirection();
    18 
    1929app.UseAuthorization();
    20 
    2130app.MapControllers();
    2231
  • iknow-api/appsettings.json

    rc11d3a3 r8e32210  
    66    }
    77  },
    8   "AllowedHosts": "*"
     8  "ConnectionStrings": {
     9    "DefaultConnection": "Host=localhost;Port=55432;Database=myappdb;Username=postgres;Password=REDACTED_ROTATE_ME"
     10  },
     11  "Jwt": {
     12    "Key": "REDACTED_SET_VIA_USER_SECRETS"
     13  }
    914}
  • iknow-api/iknow-api.csproj

    rc11d3a3 r8e32210  
    99
    1010  <ItemGroup>
     11    <PackageReference Include="BCrypt.Net-Next" Version="4.0.3" />
    1112    <PackageReference Include="Microsoft.AspNetCore.OpenApi" Version="9.0.9" />
     13    <PackageReference Include="Microsoft.EntityFrameworkCore.Design" Version="9.0.10">
     14      <IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
     15      <PrivateAssets>all</PrivateAssets>
     16    </PackageReference>
     17    <PackageReference Include="Npgsql.EntityFrameworkCore.PostgreSQL" Version="9.0.4" />
     18    <PackageReference Include="System.IdentityModel.Tokens.Jwt" Version="8.14.0" />
    1219  </ItemGroup>
    1320
Note: See TracChangeset for help on using the changeset viewer.