Add user management system with JWT authentication

- Database schema: users, permissions, client_access tables
- Auth: JWT tokens with Argon2 password hashing
- API: login, user CRUD, permission management
- Dashboard: login required, admin Users tab
- Auto-creates initial admin user on first run
This commit is contained in:
2025-12-29 20:57:30 -07:00
parent 743b73dfe7
commit 3fc4e1f96a
13 changed files with 2354 additions and 70 deletions

View File

@@ -7,6 +7,7 @@ pub mod machines;
pub mod sessions;
pub mod events;
pub mod support_codes;
pub mod users;
use anyhow::Result;
use sqlx::postgres::PgPoolOptions;
@@ -17,6 +18,7 @@ pub use machines::*;
pub use sessions::*;
pub use events::*;
pub use support_codes::*;
pub use users::*;
/// Database connection pool wrapper
#[derive(Clone)]