Skip to content

Commit

Permalink
Merge pull request #830 from skoruba/release/2.0.0
Browse files Browse the repository at this point in the history
Release/2.0.0 馃殌
  • Loading branch information
skoruba committed Apr 26, 2021
2 parents 4993559 + 8b1d79c commit b92609a
Show file tree
Hide file tree
Showing 3,180 changed files with 69,440 additions and 179,961 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
4 changes: 2 additions & 2 deletions .gitignore
Expand Up @@ -275,9 +275,9 @@ __pycache__/
/src/Skoruba.IdentityServer4.Admin/Data/Migrations/

# Don't ignore these log folders
!/src/Skoruba.IdentityServer4.Admin/Resources/Views/Log/
!/src/Skoruba.IdentityServer4.Admin.UI/Resources/Views/Log/
!/src/Skoruba.IdentityServer4.Admin.BusinessLogic/Dtos/Log/
!/src/Skoruba.IdentityServer4.Admin/Views/Log/
!**/Views/Log/
!/src/Skoruba.IdentityServer4.Admin.BusinessLogic/Events/Log/
/src/Skoruba.IdentityServer4.Admin.Api/appsettings.Production.json

Expand Down
76 changes: 38 additions & 38 deletions README.md
Expand Up @@ -2,38 +2,30 @@

# Skoruba.IdentityServer4.Admin

> The administration of the IdentityServer4 and Asp.Net Core Identity
> The administration for the IdentityServer4 and Asp.Net Core Identity
## Project Status

[![Build status](https://ci.appveyor.com/api/projects/status/5yg59bn70399hn6s/branch/master?svg=true)](https://ci.appveyor.com/project/JanSkoruba/identityserver4-admin/branch/master)
[![Build Status](https://dev.azure.com/skoruba/IdentityServer4.Admin/_apis/build/status/IdentityServer4.Admin-CI?branchName=master)](https://dev.azure.com/skoruba/IdentityServer4.Admin/_build/latest?definitionId=2?branchName=master)
[![Join the chat at https://gitter.im/skoruba/IdentityServer4.Admin](https://badges.gitter.im/skoruba/IdentityServer4.Admin.svg)](https://gitter.im/skoruba/IdentityServer4.Admin?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)

The application is written in the **Asp.Net Core MVC - using .NET Core 3.1**
The application is written in the **Asp.Net Core MVC - using .NET 5**

## Requirements

- [Install](https://www.microsoft.com/net/download/windows#/current) the latest .NET Core 3.x SDK (using older versions may lead to 502.5 errors when hosted on IIS or application exiting immediately after starting when self-hosted)
- [Install](https://www.microsoft.com/net/download/windows#/current) the latest .NET 5 SDK (using older versions may lead to 502.5 errors when hosted on IIS or application exiting immediately after starting when self-hosted)

## Installation via dotnet new template

- Install the dotnet new template:

### Stable version 1.0.0 works with **IdentityServer4 version 3** 馃殌

```sh
dotnet new -i Skoruba.IdentityServer4.Admin.Templates::1.0.0
```

### Beta version 2.0.0 works with **IdentityServer4 version 4** 馃殌
### Version 2.0.0 works with **IdentityServer4 version 4** 馃殌

- 馃敀 **NOTE:** This version affects your database data if you use the default database migrations that are part of the project - double check the migrations according to your database provider and create a database backup

- The source code for version **2.0.0** is available in the branch [release/2.0.0-beta1](https://github.com/skoruba/IdentityServer4.Admin/tree/release/2.0.0-beta1)

```sh
dotnet new -i Skoruba.IdentityServer4.Admin.Templates::2.0.0-beta1
dotnet new -i Skoruba.IdentityServer4.Admin.Templates::2.0.0
```

### Create new project:
Expand Down Expand Up @@ -79,17 +71,21 @@ Project template options:

- This administration uses bootstrap 4

- Admin UI
### Admin UI - Light mode 馃尀

![Admin-preview](docs/Images/App/1.PNG)

![Admin-preview](docs/Images/App/Skoruba-Home-Preview.PNG)
### Admin UI - Dark mode 馃寵

- Security token service (STS)
![Admin-preview](docs/Images/App/2.PNG)

![Admin-preview](docs/Images/App/Skoruba-STS-Home-Preview.PNG)
### Security token service (STS)

- Forms:
![Admin-preview](docs/Images/App/4.PNG)

![Admin-preview-form](docs/Images/App/Skoruba-Forms-Preview.PNG)
### Forms

![Admin-preview-form](docs/Images/App/3.png)

## Cloning

Expand Down Expand Up @@ -170,21 +166,12 @@ docker-compose up -d
### Docker images
- Docker images will be available also in [docker hub](https://hub.docker.com/u/skoruba)
- AdminUI:
- **Stable version:**
- `skoruba/identityserver4-admin:1.0.0`
- **Beta version:**
- `skoruba/identityserver4-admin:2.0.0-beta1`
- AdminUI:
- `skoruba/identityserver4-admin:2.0.0`
- Admin Api:
- **Stable version:**
- `skoruba/identityserver4-admin-api:1.0.0`
- **Beta version:**
- `skoruba/identityserver4-admin-api:2.0.0-beta1`
- `skoruba/identityserver4-admin-api:2.0.0`
- STS:
- **Stable version:**
- `skoruba/identityserver4-sts-identity:1.0.0`
- **Beta version:**
- `skoruba/identityserver4-sts-identity:2.0.0-beta1`
- `skoruba/identityserver4-sts-identity:2.0.0`

### Publish Docker images to Docker hub
- Check the script in `build/publish-docker-images.ps1` - change the profile name according to your requirements.
Expand All @@ -208,6 +195,7 @@ The following Gulp commands are available:
- `gulp scripts` - bundle and minify JS
- `gulp clean` - remove the `dist` folder
- `gulp build` - run the `styles` and `scripts` tasks
- `gulp watch` - watch all changes in all sass files

## EF Core & Data Access

Expand Down Expand Up @@ -397,6 +385,8 @@ Admin and STS can be customized without editing code in `appsettings.json` under

Ui can be customized using themes integrated from [bootswatch](https://bootswatch.com).

From version 2.0.0 is possible to change theme from UI. 馃巿

By default, configuration value is null to use default theme. if you want to use a theme, just fill the lowercase theme name as configuration value of `Theme` key.

You can also use your custom theme by integrating it in your project or hosting css on your place to pass the url in `CustomThemeCss` key. (Note that custom theme override standard theme)
Expand Down Expand Up @@ -600,18 +590,24 @@ Integration tests use StartupTest class which is pre-configured with:

- Admin UI:

- `Skoruba.IdentityServer4.Admin` - ASP.NET Core MVC application that contains Admin UI
- `Skoruba.IdentityServer4.Admin.UI` - ASP.NET Core MVC application that contains Admin UI

- `Skoruba.IdentityServer4.Admin` - ASP.NET Core MVC application that uses Admin UI package and it's only for application bootstrap

- `Skoruba.IdentityServer4.Admin.BusinessLogic` - project that contains Dtos, Repositories, Services and Mappers for the IdentityServer4

- `Skoruba.IdentityServer4.Admin.BusinessLogic.Identity` - project that contains Dtos, Repositories, Services and Mappers for the Asp.Net Core Identity

- `Skoruba.IdentityServer4.Admin.BusinessLogic.Shared` - project that contains shared Dtos and ExceptionHandling for the Business Logic layer of the IdentityServer4 and Asp.Net Core Identity

- `Skoruba.IdentityServer4.Shared` - Shared common layer for Admin UI, Admin UI Api and STS
- `Skoruba.IdentityServer4.Shared` - Shared common Identity DTOS for Admin UI, Admin UI Api and STS

- `Skoruba.IdentityServer4.Shared.Configuration` - Shared common layer for Admin UI, Admin UI Api and STS

- `Skoruba.IdentityServer4.Admin.EntityFramework` - EF Core data layer that contains Entities for the IdentityServer4

- `Skoruba.IdentityServer4.Admin.EntityFramework.Configuration` - EF Core data layer that contains configurations

- `Skoruba.IdentityServer4.Admin.EntityFramework.Identity` - EF Core data layer that contains Repositories for the Asp.Net Core Identity

- `Skoruba.IdentityServer4.Admin.EntityFramework.Extensions` - project that contains extensions related to EntityFramework
Expand Down Expand Up @@ -648,7 +644,7 @@ It is possible to define the configuration according the client type - by defaul
- Empty
- Web Application - Server side - Authorization Code Flow with PKCE
- Single Page Application - Javascript - Authorization Code Flow with PKCE
- Native Application - Mobile/Desktop - Hybrid flow
- Native Application - Mobile/Desktop - Authorization Code Flow with PKCE
- Machine/Robot - Client Credentials flow
- TV and Limited-Input Device Application - Device flow

Expand Down Expand Up @@ -742,12 +738,16 @@ It is possible to define the configuration according the client type - by defaul

### 2.0.0
- [x] Update to IdentityServer4 version 4 ([#633](https://github.com/skoruba/IdentityServer4.Admin/issues/633))
- [x] Add support for themes ([#725](https://github.com/skoruba/IdentityServer4.Admin/issues/725))
- [x] Extract UI part into nuget package ([#770](https://github.com/skoruba/IdentityServer4.Admin/issues/770), [#409](https://github.com/skoruba/IdentityServer4.Admin/issues/409), [#55](https://github.com/skoruba/IdentityServer4.Admin/issues/55), [#322](https://github.com/skoruba/IdentityServer4.Admin/issues/322), [#28](https://github.com/skoruba/IdentityServer4.Admin/issues/28), [#133](https://github.com/skoruba/IdentityServer4.Admin/issues/133))

### 3.0.0:
### 3.0.0
- [ ] Connect Admin Api to the Admin UI ([#478](https://github.com/skoruba/IdentityServer4.Admin/issues/478))

### 4.0.0:

- [ ] Create a project template using dotnet CLI - `dotnet new template`
- [ ] Second template: The administration of the IdentityServer4 (without Asp.Net Core Identity) ([#79](https://github.com/skoruba/IdentityServer4.Admin/issues/79))
- [ ] Connect Admin Api to the Admin UI ([#478](https://github.com/skoruba/IdentityServer4.Admin/issues/478))
- [ ] Add windows authentication ([#479](https://github.com/skoruba/IdentityServer4.Admin/issues/479))


Expand All @@ -756,7 +756,7 @@ It is possible to define the configuration according the client type - by defaul
- Add UI tests ([#97](https://github.com/skoruba/IdentityServer4.Admin/issues/97), [#116](https://github.com/skoruba/IdentityServer4.Admin/issues/116))
- Add more unit and integration tests :blush:
- Extend administration for another protocols
- Create separate UI using `Razor Class Library` ([#28](https://github.com/skoruba/IdentityServer4.Admin/issues/28), [#133](https://github.com/skoruba/IdentityServer4.Admin/issues/133))


## Licence

Expand Down
21 changes: 21 additions & 0 deletions Skoruba.IdentityServer4.Admin.sln
Expand Up @@ -51,6 +51,12 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Skoruba.IdentityServer4.Adm
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Skoruba.IdentityServer4.Shared", "src\Skoruba.IdentityServer4.Shared\Skoruba.IdentityServer4.Shared.csproj", "{61B285F0-EE06-4AEE-AAF3-71492CBD11C5}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Skoruba.IdentityServer4.Admin.UI", "src\Skoruba.IdentityServer4.Admin.UI\Skoruba.IdentityServer4.Admin.UI.csproj", "{6DD24C2C-0FB5-4C37-8B42-5DACA0FDE4EC}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Skoruba.IdentityServer4.Admin.EntityFramework.Configuration", "src\Skoruba.IdentityServer4.Admin.EntityFramework.Configuration\Skoruba.IdentityServer4.Admin.EntityFramework.Configuration.csproj", "{45FB23BE-A7F9-4172-8868-B5E387007644}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Skoruba.IdentityServer4.Shared.Configuration", "src\Skoruba.IdentityServer4.Shared.Configuration\Skoruba.IdentityServer4.Shared.Configuration.csproj", "{D49A2D61-AEEB-457C-B3BA-D1322EB2F4EC}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand Down Expand Up @@ -133,6 +139,18 @@ Global
{61B285F0-EE06-4AEE-AAF3-71492CBD11C5}.Debug|Any CPU.Build.0 = Debug|Any CPU
{61B285F0-EE06-4AEE-AAF3-71492CBD11C5}.Release|Any CPU.ActiveCfg = Release|Any CPU
{61B285F0-EE06-4AEE-AAF3-71492CBD11C5}.Release|Any CPU.Build.0 = Release|Any CPU
{6DD24C2C-0FB5-4C37-8B42-5DACA0FDE4EC}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{6DD24C2C-0FB5-4C37-8B42-5DACA0FDE4EC}.Debug|Any CPU.Build.0 = Debug|Any CPU
{6DD24C2C-0FB5-4C37-8B42-5DACA0FDE4EC}.Release|Any CPU.ActiveCfg = Release|Any CPU
{6DD24C2C-0FB5-4C37-8B42-5DACA0FDE4EC}.Release|Any CPU.Build.0 = Release|Any CPU
{45FB23BE-A7F9-4172-8868-B5E387007644}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{45FB23BE-A7F9-4172-8868-B5E387007644}.Debug|Any CPU.Build.0 = Debug|Any CPU
{45FB23BE-A7F9-4172-8868-B5E387007644}.Release|Any CPU.ActiveCfg = Release|Any CPU
{45FB23BE-A7F9-4172-8868-B5E387007644}.Release|Any CPU.Build.0 = Release|Any CPU
{D49A2D61-AEEB-457C-B3BA-D1322EB2F4EC}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{D49A2D61-AEEB-457C-B3BA-D1322EB2F4EC}.Debug|Any CPU.Build.0 = Debug|Any CPU
{D49A2D61-AEEB-457C-B3BA-D1322EB2F4EC}.Release|Any CPU.ActiveCfg = Release|Any CPU
{D49A2D61-AEEB-457C-B3BA-D1322EB2F4EC}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand All @@ -156,6 +174,9 @@ Global
{0A8A0DB7-0509-4DFB-9201-74398511B481} = {2A514C8F-6A53-41CA-AB41-B644E7BC92A7}
{4D123ACB-ACBD-4E40-AE6B-1B0F79D703B0} = {0BC0CC4E-A0F1-45E8-B41A-AE0FA76BF3E5}
{61B285F0-EE06-4AEE-AAF3-71492CBD11C5} = {EE588CE5-51D0-4E98-A2B3-40EC8E655931}
{6DD24C2C-0FB5-4C37-8B42-5DACA0FDE4EC} = {588205D4-3A30-4DA4-849D-C7422C396DAA}
{45FB23BE-A7F9-4172-8868-B5E387007644} = {2A514C8F-6A53-41CA-AB41-B644E7BC92A7}
{D49A2D61-AEEB-457C-B3BA-D1322EB2F4EC} = {EE588CE5-51D0-4E98-A2B3-40EC8E655931}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {B3166EDE-037B-4C68-BEBA-5DE9C5E3DB82}
Expand Down
14 changes: 9 additions & 5 deletions build/add-migrations.ps1
@@ -1,4 +1,4 @@
param([string] $migration = 'DbInit', [string] $migrationProviderName = 'All')
param([string] $migration = 'DbInit', [string] $migrationProviderName = 'All', [string] $targetContext = 'All')
$projectName = "Skoruba.IdentityServer4";
$currentPath = Get-Location
Set-Location "../src/$projectName.Admin"
Expand All @@ -12,7 +12,7 @@ $targetContexts = @{
IdentityServerConfigurationDbContext = "Migrations\IdentityServerConfiguration";
IdentityServerPersistedGrantDbContext = "Migrations\IdentityServerGrants";
AdminAuditLogDbContext = "Migrations\AuditLogging";
IdentityServerDataProtectionDbContext = "Migrations\DataProtection";
IdentityServerDataProtectionDbContext = "Migrations\DataProtection";
}

#Initialize the db providers and it's respective projects
Expand Down Expand Up @@ -41,10 +41,14 @@ foreach ($provider in $dpProviders.Keys) {
$settings | set-content appsettings.json
if ((Test-Path $projectPath) -eq $true) {
foreach ($context in $targetContexts.Keys) {
$migrationPath = $targetContexts[$context];

if ($targetContext -eq 'All' -or $context -eq $targetContext) {

Write-Host "Migrating context " $context
dotnet ef migrations add $migration -c $context -o $migrationPath -p $projectPath
$migrationPath = $targetContexts[$context];

Write-Host "Migrating context " $context
dotnet ef migrations add $migration -c $context -o $migrationPath -p $projectPath
}
}
}

Expand Down
9 changes: 8 additions & 1 deletion build/create-nuget-packages.ps1
@@ -1,10 +1,17 @@
$packagesOutput = ".\packages"

# Business Logic
dotnet pack .\..\src\Skoruba.IdentityServer4.Admin.BusinessLogic\Skoruba.IdentityServer4.Admin.BusinessLogic.csproj -c Release -o $packagesOutput
dotnet pack .\..\src\Skoruba.IdentityServer4.Admin.BusinessLogic.Identity\Skoruba.IdentityServer4.Admin.BusinessLogic.Identity.csproj -c Release -o $packagesOutput
dotnet pack .\..\src\Skoruba.IdentityServer4.Admin.BusinessLogic.Shared\Skoruba.IdentityServer4.Admin.BusinessLogic.Shared.csproj -c Release -o $packagesOutput
dotnet pack .\..\src\Skoruba.IdentityServer4.Shared.Configuration\Skoruba.IdentityServer4.Shared.Configuration.csproj -c Release -o $packagesOutput

# EF
dotnet pack .\..\src\Skoruba.IdentityServer4.Admin.EntityFramework\Skoruba.IdentityServer4.Admin.EntityFramework.csproj -c Release -o $packagesOutput
dotnet pack .\..\src\Skoruba.IdentityServer4.Admin.EntityFramework.Extensions\Skoruba.IdentityServer4.Admin.EntityFramework.Extensions.csproj -c Release -o $packagesOutput
dotnet pack .\..\src\Skoruba.IdentityServer4.Admin.EntityFramework.Identity\Skoruba.IdentityServer4.Admin.EntityFramework.Identity.csproj -c Release -o $packagesOutput
dotnet pack .\..\src\Skoruba.IdentityServer4.Admin.EntityFramework.Shared\Skoruba.IdentityServer4.Admin.EntityFramework.Shared.csproj -c Release -o $packagesOutput
dotnet pack .\..\src\Skoruba.IdentityServer4.Admin.EntityFramework.Shared\Skoruba.IdentityServer4.Admin.EntityFramework.Shared.csproj -c Release -o $packagesOutput
dotnet pack .\..\src\Skoruba.IdentityServer4.Admin.EntityFramework.Configuration\Skoruba.IdentityServer4.Admin.EntityFramework.Configuration.csproj -c Release -o $packagesOutput

# UI
dotnet pack .\..\src\Skoruba.IdentityServer4.Admin.UI\Skoruba.IdentityServer4.Admin.UI.csproj -c Release -o $packagesOutput
7 changes: 6 additions & 1 deletion build/publish-nuget-packages.ps1
Expand Up @@ -7,4 +7,9 @@ dotnet nuget push ./packages/Skoruba.IdentityServer4.Admin.BusinessLogic.Shared.
dotnet nuget push ./packages/Skoruba.IdentityServer4.Admin.EntityFramework.$version.nupkg -k $key -s https://api.nuget.org/v3/index.json
dotnet nuget push ./packages/Skoruba.IdentityServer4.Admin.EntityFramework.Extensions.$version.nupkg -k $key -s https://api.nuget.org/v3/index.json
dotnet nuget push ./packages/Skoruba.IdentityServer4.Admin.EntityFramework.Identity.$version.nupkg -k $key -s https://api.nuget.org/v3/index.json
dotnet nuget push ./packages/Skoruba.IdentityServer4.Admin.EntityFramework.Shared.$version.nupkg -k $key -s https://api.nuget.org/v3/index.json
dotnet nuget push ./packages/Skoruba.IdentityServer4.Admin.EntityFramework.Shared.$version.nupkg -k $key -s https://api.nuget.org/v3/index.json

dotnet nuget push ./packages/Skoruba.IdentityServer4.Admin.EntityFramework.Configuration.$version.nupkg -k $key -s https://api.nuget.org/v3/index.json
dotnet nuget push ./packages/Skoruba.IdentityServer4.Shared.Configuration.$version.nupkg -k $key -s https://api.nuget.org/v3/index.json

dotnet nuget push ./packages/Skoruba.IdentityServer4.Admin.UI.$version.nupkg -k $key -s https://api.nuget.org/v3/index.json

0 comments on commit b92609a

Please sign in to comment.