-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Extract UI project for use in existing setups (v2) (#779)
* Update README * Moved UI folders and files to new Admin.UI project * Fixed application version page can no longer refer to Startup type for detecting assembly version * Fixed build of Admin project that now depends on UI project * Extracted UI-specific startup helpers and classes into UI project * Removed bogus project dependency * Removed now unused namespace imports in map app startup helpers * Moved styles and scripts and more helpers to UI project * Moved back root configuration to Admin app because database migration and seeding is probably out of scope of UI * Moved startup service configuration to UI project through dependency injection helpers * Moved back one constant unrelated to UI into main project * Refactored UI project namespaces for consistency * Fixed some build issues * Stub for app builder extensions for UI project * Fixed test project build * Moved security headers feature to UI project * Moved startup app building to UI project * Fixed authorization middleware setup * Fixed UI view build * Fixed views cannot be resolved * Fixed static assets not accessible from root URL (e.g. ~/) * Cleaned up startup * Added convenience DI extensions for setting up UI * Cleaned up startup test * Moved migration helpers to UI project * Support for custom migration assemblies * Moved migration helpers and config down to EntityFramework.Shared * Fixed build and tests * Fixed DI UI helper not using custom entity types completely * Moved UI config json files to UI project * Disabled unused code in startup * Minor code style * Fixed view localization of UI failing when used in custom web app project * Refactored middleware configuration to simplify usage of Use* methods in Startup * Added configuration of health checks middleware * Options to further configure the auth pipelines, and better separation of endpoint routing * Ported UI to area * Fixed test build * Fixed seeding not working due to missing configuration bind * Fixed missing new views after merge * Fixed missing areas in new views * Fixed test build Co-authored-by: janskoruba <[email protected]>
- Loading branch information
1 parent
e2a5968
commit 7d8f493
Showing
1,104 changed files
with
1,262 additions
and
746 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
27 changes: 27 additions & 0 deletions
27
...ntityServer4.Admin.EntityFramework.Shared/Configuration/ConnectionStringsConfiguration.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
namespace Skoruba.IdentityServer4.Admin.EntityFramework.Shared.Configuration | ||
{ | ||
public class ConnectionStringsConfiguration | ||
{ | ||
public string ConfigurationDbConnection { get; set; } | ||
|
||
public string PersistedGrantDbConnection { get; set; } | ||
|
||
public string AdminLogDbConnection { get; set; } | ||
|
||
public string IdentityDbConnection { get; set; } | ||
|
||
public string AdminAuditLogDbConnection { get; set; } | ||
|
||
public string DataProtectionDbConnection { get; set; } | ||
|
||
public void SetConnections(string commonConnectionString) | ||
{ | ||
AdminAuditLogDbConnection = commonConnectionString; | ||
AdminLogDbConnection = commonConnectionString; | ||
ConfigurationDbConnection = commonConnectionString; | ||
DataProtectionDbConnection = commonConnectionString; | ||
IdentityDbConnection = commonConnectionString; | ||
PersistedGrantDbConnection = commonConnectionString; | ||
} | ||
} | ||
} |
29 changes: 29 additions & 0 deletions
29
...tityServer4.Admin.EntityFramework.Shared/Configuration/DatabaseMigrationsConfiguration.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
namespace Skoruba.IdentityServer4.Admin.EntityFramework.Shared.Configuration | ||
{ | ||
public class DatabaseMigrationsConfiguration | ||
{ | ||
public bool ApplyDatabaseMigrations { get; set; } = false; | ||
|
||
public string ConfigurationDbMigrationsAssembly { get; set; } | ||
|
||
public string PersistedGrantDbMigrationsAssembly { get; set; } | ||
|
||
public string AdminLogDbMigrationsAssembly { get; set; } | ||
|
||
public string IdentityDbMigrationsAssembly { get; set; } | ||
|
||
public string AdminAuditLogDbMigrationsAssembly { get; set; } | ||
|
||
public string DataProtectionDbMigrationsAssembly { get; set; } | ||
|
||
public void SetMigrationsAssemblies(string commonMigrationsAssembly) | ||
{ | ||
AdminAuditLogDbMigrationsAssembly = commonMigrationsAssembly; | ||
AdminLogDbMigrationsAssembly = commonMigrationsAssembly; | ||
ConfigurationDbMigrationsAssembly = commonMigrationsAssembly; | ||
DataProtectionDbMigrationsAssembly = commonMigrationsAssembly; | ||
IdentityDbMigrationsAssembly = commonMigrationsAssembly; | ||
PersistedGrantDbMigrationsAssembly = commonMigrationsAssembly; | ||
} | ||
} | ||
} |
2 changes: 1 addition & 1 deletion
2
...er4.Admin/Configuration/Identity/Claim.cs → ...rk.Shared/Configuration/Identity/Claim.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...ver4.Admin/Configuration/Identity/Role.cs → ...ork.Shared/Configuration/Identity/Role.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...ver4.Admin/Configuration/Identity/User.cs → ...ork.Shared/Configuration/Identity/User.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
11 changes: 11 additions & 0 deletions
11
src/Skoruba.IdentityServer4.Admin.EntityFramework.Shared/Configuration/IdentityData.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
using Skoruba.IdentityServer4.Admin.EntityFramework.Shared.Configuration.Identity; | ||
using System.Collections.Generic; | ||
|
||
namespace Skoruba.IdentityServer4.Admin.EntityFramework.Shared.Configuration | ||
{ | ||
public class IdentityData | ||
{ | ||
public List<Role> Roles { get; set; } | ||
public List<User> Users { get; set; } | ||
} | ||
} |
4 changes: 2 additions & 2 deletions
4
...in/Configuration/IdentityServer/Client.cs → ...ed/Configuration/IdentityServer/Client.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 3 additions & 3 deletions
6
...ration/IdentityServerDataConfiguration.cs → ...hared/Configuration/IdentityServerData.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
....Admin/Configuration/SeedConfiguration.cs → ...Shared/Configuration/SeedConfiguration.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.