{
"JWT": {
"ValidIssuer": "",
"ValidAudience": "",
"Secret": ""
},
"Stripe": {
"ApiKey": "",
"PublishableKey": ""
},
"Cloudinary": {
"CloudName": "",
"ApiKey": "",
"ApiSecret": ""
},
"Smtp": {
"ApiKey": "",
"Server": "",
"Port": "",
"SenderName": "",
"SenderEmail": "",
"Password": ""
}
}
You can put it in appsettings.json, dotnet usersecrets, or whatever thing that allows you to admin your environments variables
If you want to apply migrations you need to provide these variables to the command
--project src/Ecommerce.Infrastructure
--startup-project src/Ecommerce.Api
--output-dir Persistence/Migrations
The command should look like this:
dotnet migrations add "yourmigrations" --project src/Ecommerce.Infrastructure --startup-project src/Ecommerce.Api --output-dir Persistence/Migrations
The application needs two database for hangfire.
docker exect -it <containerId> /opt/mssql-tools/bin/sqlcmd -S localhost -U sa -P <yourPassword>
CREATE DATABASE [HangfireDb]
GO
CREATE DATABASE [HangfireTestDb]
GO
All domain models are here, this layer cannot depend on any other layer.
In this layer you find the domain services and some abstractions of the app
This layer manages all external dependencies such as stripe, Cloudinary, and so on and also only depends on the core layer
This layer is a shared classlib to be able to communicate with the api from other app, for example a web-client or mobil-client can communicate with the api using this classlib with refit.
this layer is a web API and depends on core and infrastructure layers
This project is licensed with the MIT license.