T-HUB/apps/api/src/group-files/group-files.module.ts
glass beadian fe5f2403d6 feat: in-app Chat (Matrix JWT SSO) + Drive (embedded oCIS)
- api: matrix-sso module (tuwunel jwt -> login/get_token), POST /matrix/session, GET /matrix/identity, drive controller
- web: /chat full-height Element view, /files Library+Drive tabs, embedded-app frame component
- edge: /hub-sso.html handshake route (origin-pinned CSP), X-Frame-Options strip on files
- oCIS: csp.yaml frame-ancestors app.occupymedia.cc
- server config still required: tuwunel [global.jwt], MATRIX_SSO_JWT_SECRET, oCIS restart
2026-10-13 14:57:07 +00:00

28 lines
1.2 KiB
TypeScript

import { Module } from "@nestjs/common";
import { GroupFilesController, PublicFileShareController } from "./group-files.controller.js";
import { GroupFilesService } from "./group-files.service.js";
import { DriveController } from "./drive.controller.js";
/**
* Group files module — the metadata index + share/link lifecycle over
* chat_media_archive (029) and the oCIS WebDAV port (occ-files deploy).
*
* NOT registered in AppModule by this slice: per the deployment contract
* (infra/occupymedia/files/README.md) the oCIS service is scaffolded
* separately and admission checks are mandatory before this surface accepts
* user payloads. Wiring is one line in apps/api/src/app.module.ts:
*
* imports: [..., GroupFilesModule]
*
* until that gate is passed — the ChatgovModule precedent.
*
* The oCIS client is built lazily from env on first use, so importing the
* module never requires FILES_OCID_* to be present; routes fail 503 when the
* deployment is absent instead of breaking startup.
*/
@Module({
controllers: [GroupFilesController, PublicFileShareController, DriveController],
providers: [GroupFilesService],
exports: [GroupFilesService],
})
export class GroupFilesModule {}