8e717401bd
refactor(acadedoc): move branding from .env to UI-only — Patch 020
...
Per Corentin's feedback (2026-05-08): .env should be reserved for
server-side config (SMTP, DB, OIDC). Branding (name, colors, logo)
is admin/UI territory.
Changes:
- Remove BRAND_NAME / BRAND_LOGO_URL / BRAND_PRIMARY_COLOR /
BRAND_ACCENT_COLOR from .env.example, vite.config.ts define block
- Hardcode "AcadeDoc" + #2563eb / #7c3aed as defaults in
apps/client/src/lib/config.ts and brand-theme.ts
- getBrandTheme() now takes optional runtime overrides instead of
reading process.env (used by per-workspace branding hook to apply
DB-stored colors)
- Server getMailFromName() defaults to "AcadeDoc" hardcoded; only
MAIL_FROM_NAME env var can override
- Fix workspace-branding.spec.ts (was importing vitest in jest project,
R4.4 leftover bug, similar to Patch 017 scope)
- Fix environment.service.spec.ts (was missing ConfigService provider
in TestingModule, pre-existing upstream bug surfaced by jest run)
Tests: 13 brand-theme + 13 workspace-branding + 2 environment = 28
green. Per-workspace UI override via /settings/branding (R4.4) works
unchanged.
Patch 020.
2026-05-08 11:49:49 +02:00
b53ab5043f
feat(acadedoc): add AcadeDoc branding, Brevo SMTP preset, UI customization — R4.4
...
- Rebranding: BRAND_NAME env var (default AcadeDoc) replaces hardcoded "DocAdenice"
in index.html title/meta, PWA manifest, app-header logo text, email footer/body
- lib/config.ts: getAppName() reads BRAND_NAME; new getBrandLogoUrl/PrimaryColor/AccentColor helpers
- vite.config.ts: BRAND_* vars exposed via define block to client
- brand-theme.ts: getBrandTheme() generates 10-shade MantineColorsTuple from hex
(no @mantine/colors-generator dep); merged into MantineProvider at boot
- theme/__tests__/brand-theme.test.ts: 11 vitest tests (generateColorTuple + getBrandTheme)
- Workspace branding: migration adds primary_color/accent_color to workspaces table
WorkspaceBrandingService + WorkspaceBrandingController (POST /workspace/branding,
POST /workspace/branding/update — admin only) + DTO hex validation
- Settings: /settings/branding page (WorkspaceBranding) + sidebar entry (admin-only)
- workspace-branding.spec.ts: 13 vitest tests (service + controller + DTO validation)
- SMTP Brevo: .env.example preset block + transactional/README.md ops guide
(key gen, port 587 STARTTLS, 300/day free limit, swaks/curl test)
- environment.service.ts: getMailFromName() falls back to BRAND_NAME if MAIL_FROM_NAME unset
- vitest.config.ts server: include pattern extended to src/core/workspace/spec/**
- i18n: 11 branding keys added to en-US and fr-FR translations
- 0 TypeScript errors client + server, 11 client + 13 server new tests all green
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-08 11:36:38 +02:00
06c46f7b9b
fix(oidc): defaut OIDC_SCOPES align Authentik (sans 'groups')
...
Authentik n'expose pas un scope 'groups' standard — demander ce scope
inconnu peut faire echouer l'authorize selon la config provider. Les
groups arrivent dans le claim 'groups' du scope 'profile' par defaut.
Defaut passe de 'openid email profile groups' vers 'openid email profile'.
Update env.example + ACADENICE_PATCHES.md doc associee.
2026-05-07 21:28:40 +02:00
07d0b66fda
feat(auth): Bloc 4b — OIDC client Authentik via openid-client (active par OIDC_ENABLED env)
...
Ajoute un flow d'authentification OIDC via Authentik (ou tout IdP conforme),
desactive par defaut. Le code est dormant tant que OIDC_ENABLED=true n'est
pas pose.
Server :
- apps/server/src/core/auth/oidc/oidc.module.ts (nouveau)
- apps/server/src/core/auth/oidc/oidc.service.ts (discovery + PKCE + callback + JIT provisioning)
- apps/server/src/core/auth/oidc/oidc.controller.ts (routes /api/auth/oidc/{login,callback,status})
- apps/server/src/core/auth/oidc/oidc.service.spec.ts (8 tests Jest, openid-client mocke)
- apps/server/src/integrations/environment/environment.service.ts : +9 getters OIDC
- apps/server/src/core/core.module.ts : +OidcModule dans imports
Client :
- apps/client/src/features/auth/queries/oidc-query.ts (hook useOidcStatus)
- apps/client/src/features/auth/components/oidc-login-button.tsx (bouton conditionnel)
- apps/client/src/features/auth/components/login-form.tsx : +OidcLoginButton
Securite :
- PKCE S256 obligatoire
- State CSRF en cookie httpOnly signe (5 min)
- Verification JWKS auto via openid-client v6
- Refetch userInfo apres echange du code
- JIT provisioning strict par defaut (OIDC_AUTO_PROVISION=false)
Lib : openid-client v6.8.2 (deja en deps), import lazy.
Documente dans ACADENICE_PATCHES.md (Patch 002) et .env.example.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-07 21:26:53 +02:00
Philip Okugbe
a6a7e4370a
feat(ee): PDF export api ( #2112 )
...
* feat(ee): server side PDF export
* feat: pdf export queue
* sync
* sync
2026-04-14 16:26:54 +01:00
Philip Okugbe
918f4508d2
feat: switch to pino for logs ( #1855 )
...
- switch to json logs in production
- add option to support http logging
2026-01-21 01:23:50 +00:00
Philip Okugbe
5a3377790e
feat: debug mode env variable ( #1450 )
2025-08-06 18:16:30 +01:00
Philipinho
8300c5b731
update env file
2025-03-23 13:14:20 +00:00
Philip Okugbe
72f64e7b10
revert sentry ( #808 )
...
* revert sentry
* remove sentry env
2025-02-27 15:58:32 +00:00
Philipinho
54d27af76a
* Add SENTRY_DNS env variable
...
* Commit lock file
2025-02-26 17:38:25 +00:00
Philip Okugbe
040d6625df
fix: enforce 32-character minimum length for APP_SECRET ( #702 )
...
* Enforce 32 characters minimum APP_SECRET length
* update APP_SECRET comment
2025-02-06 17:46:32 +00:00
Philip Okugbe
d97baf5824
add env variable ( #513 )
2024-11-28 18:48:25 +00:00
Philip Okugbe
384f11f2b7
make file upload size limit configurable ( #386 )
2024-10-10 21:28:28 +01:00
Orion
9390b39e35
Implement nodemailer ignore tls property ( #299 )
2024-09-20 17:57:50 +01:00
sidnelui-krystal
c810d0b314
fix: added env variable for support for forcepathstyle on s3 ( #181 )
2024-08-20 13:05:59 +01:00
Philipinho
4967849e3a
add SMTP_SECURE
2024-08-02 11:19:12 +02:00
Philipinho
bc7cd033f2
more env validations
2024-06-27 22:47:59 +01:00
Philipinho
a582d4786d
make env validation errors clear
...
* modify mail smtp variable names
2024-06-27 17:55:17 +01:00
Philipinho
38ef610e5e
fixes
...
* integrate websocket redis adapter
* use APP_SECRET for jwt signing
* auto migrate database on startup in production
* add updatedAt to update db operations
* create enterprise ee package directory
* fix comment editor focus
* other fixes
2024-06-07 17:29:34 +01:00
Philipinho
eefe63d1cd
implement new invitation system
...
* fix comments on the frontend
* move jwt token service to its own module
* other fixes and updates
2024-05-14 22:55:11 +01:00
Philipinho
7f933addff
Implement BullMQ for background job processing
...
* new REDIS_URL environment variable
2024-05-03 02:56:03 +01:00
Philipinho
4c573b9bc2
email integration
...
* Nest email module with smtp, postmark and console log drivers
* react-email package
2024-05-02 03:12:40 +01:00
Philipinho
f01b77dbd6
fixes
...
* remove vite env for now
* remove unnecessary comment
2024-04-25 22:36:03 +01:00
Philipinho
616da875cd
move .env to root
2024-01-17 18:36:54 +01:00