feat: implement Redis session management and user authentication flow

This commit is contained in:
2025-12-30 01:38:09 +00:00
parent 1688ca0d23
commit 29523ef22f
20 changed files with 820 additions and 5 deletions
+30 -1
View File
@@ -1 +1,30 @@
export {};
import path from 'node:path';
import { fileURLToPath } from 'node:url';
import { runGatewayApiServer } from './server.js';
export * from './config.js';
export * from './context.js';
export * from './router.js';
export * from './server.js';
export * from './auth/userRepository.js';
export * from './auth/passwordHasher.js';
export * from './auth/inMemoryUserRepository.js';
export * from './auth/sessionService.js';
export * from './auth/inMemorySessionService.js';
export * from './auth/redisSessionService.js';
export * from './auth/redisKeys.js';
const isMain = (): boolean => {
if (!process.argv[1]) {
return false;
}
return fileURLToPath(import.meta.url) === path.resolve(process.argv[1]);
};
if (isMain()) {
runGatewayApiServer().catch((error) => {
console.error('[gateway-api] failed to start', error);
process.exitCode = 1;
});
}