feat(api): Protokollzeile je Anfrage und je Nextcloud-Pruefung im Docker-Log

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-10-02 23:42:10 +02:00
parent fffb7ffbec
commit 0afcf237e8
5 changed files with 96 additions and 4 deletions
+5 -4
View File
@@ -3,12 +3,16 @@ import { ConfigService } from '@nestjs/config';
import { NestFactory } from '@nestjs/core';
import cookieParser from 'cookie-parser';
import { AppModule } from './app.module';
import { requestLogMiddleware } from './common/request-log';
import { formatAppVersionLine } from './health/app-version';
async function bootstrap() {
const app = await NestFactory.create(AppModule);
const configService = app.get(ConfigService);
// Eine Zeile je Anfrage im Docker-Log (Pfad, Status, Dauer, Benutzer)
app.use(requestLogMiddleware);
// Cookie parser for JWT httpOnly cookies
app.use(cookieParser());
@@ -21,10 +25,7 @@ async function bootstrap() {
);
// CORS with credentials for cross-origin cookie support (Pitfall 4)
const corsOrigin = configService.get<string>(
'CORS_ORIGIN',
'http://localhost:3000',
);
const corsOrigin = configService.get<string>('CORS_ORIGIN', 'http://localhost:3000');
app.enableCors({
origin: corsOrigin,
credentials: true,