Create a Single sign on authentication server, support development many applications with only once sign on
- Visual Studio Code
- IdentityServer4
- MySQL
1. Clone/Fork this repository.
2. Create the database on MySQL server by using the dotnet cli to run the migrations from within the command
CREATE TABLE `__EFMigrationsHistory` ( `MigrationId` nvarchar(150) NOT NULL,
`ProductVersion` nvarchar(32) NOT NULL,
PRIMARY KEY (`MigrationId`) );
$env:ASPNETCORE_ENVIRONMENT = 'Development'
dotnet ef database update --context AppIdentityDbContextdotnet ef database update --context PersistedGrantDbContextSET FOREIGN_KEY_CHECKS = 0;
SET @tables = NULL;
SELECT GROUP_CONCAT(table_schema, '.', table_name) INTO @tables
FROM information_schema.tables
WHERE table_schema = 'identity'; -- specify DB name here.
SET @tables = CONCAT('DROP TABLE ', @tables);
PREPARE stmt FROM @tables;
EXECUTE stmt;
DEALLOCATE PREPARE stmt;ls
SET FOREIGN_KEY_CHECKS = 1;