Skip to content

kurnakovv/jiraF-goal

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Main repo Hits-of-Code Render Code Smells Coverage CodeQL Codecov

Goal

Microservice with goals logic.

How to start

  • Setup ApiKey
dotnet user-secrets set "GoalApiKey" "yourApiKey" --project ".\Goal\src\jiraF.Goal.API\"
  • Start project
dotnet run --property:Configuration=Release --project .\Goal\src\jiraF.Goal.API\

Project reference https://localhost:7079/swagger/index.html

How to setup db (not required)

dotnet user-secrets set "DefaultConnection" "Server=localhost;Port=5432;Database=jiraf_goal;User Id=postgres;Password=yourPassword;" --project ".\Goal\src\jiraF.Goal.API\"
  • Edit program file from
builder.Services.AddDbContext<AppDbContext>(options =>
{
    options.UseInMemoryDatabase(TestVariables.IsWorkNow
        ? Guid.NewGuid().ToString()
        : "TestData");
    //options.UseNpgsql(builder.Configuration.GetConnectionString("DefaultConnection"));
});

to

builder.Services.AddDbContext<AppDbContext>(options =>
{
    // options.UseInMemoryDatabase(TestVariables.IsWorkNow
    //     ? Guid.NewGuid().ToString()
    //     : "TestData");
    options.UseNpgsql(builder.Configuration.GetConnectionString("DefaultConnection"));
});