First Run
Clone Repo
git clone https://github.com/webinex/starter-kit
First Run
Ask Azure administrator for Service Bus connection string and topic name
Set them in:src/StarterKit/StarterKit.App.Api/appsettings.Personal.json
src/StarterKit/StarterKit.Identity/appsettings.Personal.json{
"ConnectionStrings": {
"ServiceBus": "<your-service-bus-connection-string>"
},
"Cap": {
"TopicPath": "<your cap topic name>"
}
}Ask team lead for SendGrid access key
Set it in:src/StarterKit/StarterKit.Identity/appsettings.Personal.json{
"SendGrid": {
"Key": "<your-sendgrid-key>"
}
}Create attachments folder
CreateD://starter-kit-attachmentsfolder or override attachments folder withsrc/StarterKit/StarterKit.App.Api/appsettings.Personal.json{
"Attachments": {
"BasePath": "<your-fully-qualified-path-to-attachments-folder>"
}
}Create
starter-kitdatabase
If you'd like to use another database, you need to addappsettings.Personal.jsonfiles in:src/StarterKit/StarterKit.App.Apisrc/StarterKit/StarterKit.App.Migrationssrc/StarterKit/StarterKit.Identitysrc/StarterKit/StarterKit.Identity.Migrationswith:
{
"ConnectionStrings": {
"Default": "<your-connection-string>"
}
}Apply migrations
Go tosrc/StarterKit/StarterKit.App.Migrationsand rundotnet run -- migrate
Go tosrc/StarterKit/StarterKit.Identity.Migrationsand rundotnet run -- migrateSetup SQL Server distributed cache
dotnet tool install --global dotnet-sql-cache
dotnet sql-cache create "Data Source=localhost;Initial Catalog=starter-kit;Integrated Security=True;" dbo DistributedCacheRun projects
Opensrc/StarterKit/StarterKit.slnand run projectsStarterKit.IdentityandStarterKit.App.ApiOpensrc/StarterKit/StarterKit.App.Api/ClientAppand runyarn install && yarn startSign Up
Open http://localhost:3000/sign-up and finish registration. Follow instructions in emailGive existing users admin permissions
declare @roleId uniqueidentifier = NEWID();
insert into Roles
values (@roleId, 'Admin');
insert into RolePermissions
values (@roleId, 'users.read'),
(@roleId, 'users.write'),
(@roleId, 'roles.read'),
(@roleId, 'roles.update'),
(@roleId, 'roles.create'),
(@roleId, 'roles.delete');
insert into RoleUsers (RoleId, UserId)
select @roleId, Id
from Users