Commit graph

54 commits

Author SHA1 Message Date
Pat Hartl
69e903499b Add auditing interceptor 2025-02-02 19:14:06 -06:00
Pat Hartl
123a5827c3 Remove repository 2025-02-02 18:52:47 -06:00
Pat Hartl
12c5110795 Fix non-https binding 2025-01-25 12:02:30 -06:00
Pat Hartl
7b4f2950c7 Add separate binding for SSL 2025-01-25 02:40:36 -06:00
Pat Hartl
dec4edf06d Don't log ping requests 2025-01-25 02:11:04 -06:00
Pat Hartl
b6fa4d4a10 Add ability to specify SSL certificate 2025-01-25 01:57:17 -06:00
Pat Hartl
a8ddf89eac Add cookie policies to settings 2025-01-06 20:34:57 -06:00
Pat Hartl
cbfd1fc30d Support forwarded headers 2025-01-06 17:59:53 -06:00
Pat Hartl
fb7f6b6452 Fix login routing 2025-01-06 17:03:40 -06:00
Pat Hartl
e32675f4cb HTTPS redirection 2025-01-04 18:07:37 -06:00
Pat Hartl
2c93743400 Fix missing using 2025-01-04 02:02:41 -06:00
Pat Hartl
ef8cc2ad79 Try forwarding scheme 2025-01-04 01:53:16 -06:00
Pat Hartl
78dbcdfd6c Fix auth service 2025-01-01 21:12:07 -06:00
Pat Hartl
98c0d276b0 Support OAuth as well as OIDC
- Rename ExternalProvider to AuthenticationProvider
- Add enum for authentication provider type (OAuth, SAML, OIDC, etc)
- Add claim mappings
- Move authentication provider registration to extension methods
2024-12-28 05:23:23 -06:00
Pat Hartl
11e182413d Add ability to define external authentication providers 2024-12-28 03:48:15 -06:00
Pat Hartl
ce17b7999f Rework depot results, API docs via Scalar 2024-12-16 00:57:11 -06:00
Pat Hartl
5de9eccce1 Adjust Blazor server-side to pull data with new context 2024-11-25 22:29:56 -06:00
Pat Hartl
d4ecdc5500 Remove reference to context tracker 2024-11-22 02:21:06 -06:00
Pat Hartl
00b9ca5953 Rename service and repository methods to async 2024-11-12 18:32:46 -06:00
Pat Hartl
6528015f4a Add authorization functionality to swagger 2024-11-12 02:18:04 -06:00
Pat Hartl
8996c04c83 Add eager loading to repo. Move semaphore to DbContext. Inject DbContext instead of factory to open less connections 2024-11-07 01:40:05 -06:00
Pat Hartl
4643aecc8f Remove useless startup log 2024-11-05 20:38:40 -06:00
Pat Hartl
7a90c254bd Only generate thumbnails on start if database is connected 2024-11-05 20:22:34 -06:00
Pat Hartl
e1030d25d9 Enable migrations and server autostarts 2024-11-05 20:21:28 -06:00
Pat Hartl
31433213b6 Generate thumbnails on startup 2024-11-05 20:20:03 -06:00
Pat Hartl
e30a1baef3 Start of migrations, services, controllers 2024-10-31 01:54:34 -05:00
Pat Hartl
41091e5e6d Fix redirects to login or first time setup if required 2024-10-23 22:28:55 -05:00
Pat Hartl
d045c50525 Back to scoped! 🙃 2024-10-23 02:30:18 -05:00
Pat Hartl
42ca5c323a WIP MySQL concurrency fixes
- Removed the Blazor authentication pages and went back to Razor pages
- Fixed issues with dashboard charts that were pulling data on render and causing the database context to be open longer than it should
- Switched back to UserManager and RoleManager
- Temporarily disabled authentication state in pages that might try to use user claims/roles
- Reverted spacing changes to forms to allow for validation messages
- Moved initialization of database connection to database context
- Updated PostgreSQL provider
- Rescaffolded MySQL migrations
- Added a bunch of logging stuff that should eventually be stripped out
2024-10-21 20:06:52 -05:00
Pat Hartl
84c5ed19ce Fixed AntBlazor component interactivity 2024-10-19 18:00:06 -05:00
Pat Hartl
2056b06207 Working new login page 2024-10-18 19:15:05 -05:00
Pat Hartl
fe0250c12a Register DbContextFactory and IdentityContextFactory 2024-10-16 18:41:39 -05:00
Pat Hartl
91829f601d Enable navigation properties for user roles, use service in place of managers 2024-10-16 01:54:51 -05:00
Pat Hartl
14df6bc95c Use custom models for identities 2024-10-15 23:48:16 -05:00
Pat Hartl
cf9d9f6253 Rename identity tables 2024-10-15 20:48:06 -05:00
Pat Hartl
2e5ae435bd Move Identity user store to separate database context 2024-10-14 01:29:45 -05:00
Pat Hartl
9762c803f0 Restore lazy loading 2024-10-14 01:00:12 -05:00
Pat Hartl
2805f34449 WIP fix for MySQL connection concurrency issues
This is a large commit. There are a number of things that this commit does to try to fix various issues that were occurring when the database provider was set to MySQL:
- The DAL `Repository` has been completely refactored to follow best practices. The repository is now being injected into services instead of the database context itself. This allows the DI to handle the repository's lifetime instead of creating a new repository for every transaction and sharing the context across repositories. As part of these changes, there is no more allowed usage of `IQueryable` and all service/repository methods must actually execute database queries before their return. This is to ensure that the context does not stay open longer than it needs to. Abusing `IQueryable`s by tossing them into Blazor components seems to be a big no-no.
- Some deletion behaviors on relationships have been tweaked as MySQL wasn't able to apply migrations with behaviors that were contradictory.
- A `ConnectionInterceptor` was added to try to keep track of `DatabaseContext` lifetimes. This is really only for debugging and should be put into `#if DEBUG` regions. This helped identify some potential issues where some contexts were basically never closing, causing the MySQL connector to not function.
- Docs for generating migrations have been updated to reflect the addition of being able to specify the database provider and connection string when adding a migration, avoiding the need to edit `Settings.yml`
- The application can now be put into a pause state on startup by adding the `--debugger` argument when used from the command line. When a debugger is attached, it resumes execution.
- The application can now log to Seq when using debug build
- Service lifetime on `DatabaseContext` has switched to transient. This may be reverted in the future.
- Lazy loading has been disabled for debugging purposes. It didn't directly help the concurrency issues, but it needs to be tested individually to be re-enabled.
- All usage of `UserManager`, `RoleManager`, and `SignInManager` have been removed from all controllers, pages, and Blazor components. Functionality has been moved to `UserService` and `RoleService`. This might have done the most amount of help, but could probably be improved upon in the future by not relying on them and instead having our own implementation.
- Application startup migrations and server autostarts have been disabled temporarily. There might be an issue of `DatabaseContext` lifetimes that spawn from this.
2024-10-13 20:42:45 -05:00
Pat Hartl
e236c2b25b Refactored first time setup
Fixes #128
2024-10-12 18:36:00 -05:00
Pat Hartl
07882e39d2 Add ability to specify multiple upload folders for archives
Implements #97
2024-10-11 01:09:12 -05:00
Pat Hartl
404819cdbe Enable Swagger in all builds
Implements #127
2024-10-07 20:04:48 -05:00
Pat Hartl
f4257ade10 Add migrations for MySQL and PostgreSQL 2024-10-07 19:54:22 -05:00
Pat Hartl
e083d86d8b Add ability to switch database providers to MySQL or PostgreSQL
Ref #108
2024-10-07 18:52:52 -05:00
Pat Hartl
91ee1d47a9 Move data and service layers to separate projects, update packages 2024-10-07 18:04:26 -05:00
Pat Hartl
40442c6f8b Refactor update to extract autoupdater before running it 2024-10-03 23:36:42 -05:00
Pat Hartl
910ba2367b Add basic streaming logs with color 2024-08-29 00:19:56 -05:00
Pat Hartl
c58570511f Fix Serilog registration 2024-08-28 20:47:16 -05:00
Pat Hartl
1c615cbce2 Remove nlog, use Serilog, prefer ILogger 2024-08-28 20:33:59 -05:00
Pat Hartl
78c6063b34 Add custom fields to users, move avatar uploader to component 2024-08-21 19:40:27 -05:00
Pat Hartl
cf93fb763c Start to a basic CMS editor 2024-08-19 01:22:48 -05:00