Commit Graph
392 Commits
Author SHA1 Message Date
Stanislas BruhièreandGitHub 02bce211ea ✨(frontend) add a button and modal to create maildomains (#313)
* ✨(feat) create modal, serializer and add button

* ✨(frontend) refetch on domain creation

* 🚨(frontend) fix linter

* ✅(backend) add domain creation test

* ✨(frontend) add toaster for domain creation

* 💬(frontend) add translation and fix small typo

* ✨(front+back) add custom_attributes on domain creation

* 💄(frontend) add style for create domain modal

* 💬(frontend) add missing translations + add end of file line breaks

* 🎨(frontend) move toaster to admin layout

* 🦺(frontend) validate domain name in frontend

* 💄(frontend) remove unused css

* ✅(backend) add more tests

* 🎨(backend) improve maildomain structure

* 🎨(frontend) follow nitpicks
2025-09-02 20:13:11 +02:00
Stanislas BruhièreandGitHub 38439b95ce Improve development docker compose (#324)
* 🐛(docker) stop ALL services when running make stop

* ✨(docker) make sure backend is healthy before exiting docker compose up

* 🧑‍💻 (docker) use default user and not root for healthchecks

* ➖(backend) Remove dockerflow

* ✨(backend) add healthcheck route, and suppress healthcheck access logs

* 🚨(backend) ignore monkey patching

* 🚨(backend) coderabbitai + linter fixes

* 🚚(backend) remove version in healthz route

* 🔨(docker) use python http lib instead of curl and remove curl from dockerfile
2025-09-02 12:10:52 +02:00
Stanislas Bruhiere 233e412ccd ✅(backend) change swagger url 2025-09-02 11:54:03 +02:00
Sylvain Zimmer 8f79390654 🐛(admin) allow editing full_name field 2025-09-01 22:59:23 +02:00
Sylvain Zimmer a0a7198a9b 🐛(swagger) move swagger to /api/v1.0/ like the rest 2025-08-30 19:23:20 +02:00
Sylvain Zimmer d31dfebdf2 🐛(readme) remove my personal email as contact ;) 2025-08-28 21:08:27 +02:00
Sylvain Zimmer 56a1ba69c8 🐛(blobs) delete Blobs and Attachments when Messages are deleted 2025-08-28 02:12:00 +02:00
Sylvain Zimmer 1e2f30e046 🐛(admin) use autocomplete fields instead of full dropdowns
This makes the admin usable with thousands of records in the DB
2025-08-28 00:14:29 +02:00
BastienandGitHub 0dd16f489c ✨(mta-in) enable starttls (#323)
add tls config
add STARTTLS_CHAIN_FILES env var
add openssl config for post-quantum proof
use trixie as base image, which bumps postfix to 3.10.3
2025-08-27 10:27:07 +02:00
Sylvain Zimmer 956679e9b2 ✨(dns) add button to copy all DNS records 2025-08-20 16:00:24 +02:00
Sabrina Demagny 67a7c4e9c0 ✨(api) add placeholders endpoint
This endpoint will be used for Signature and other message templates.
Update Dockerfile to include gettext for i18n compilation
2025-08-20 12:10:16 +02:00
jbpenrath 4bc83f0663 🐛(front) decrease intersection threshold to mark messages as read
The intersection threshold to mark a message as read was 0.95. That means that
95% of the message must be displayed on the screen to trigger the observer so
with long messages or on small viewport, in some cases the message could be not
mark as read.
2025-08-20 10:56:28 +02:00
Fabian ArfireandJean-Baptiste PENRATH d3fded8624 ✨(front) update label creation form to setup auto labelling
If auto labelling feature is enabled add a checkbox in the label form
to enable this feature for the given label then when the auto labelling
is enabled, show a description input to allow user to describe the label
purpose.

Co-authored-by: jbpenrath <jb.penrath@gmail.com>
2025-08-19 23:48:03 +02:00
Fabian ArfireandJean-Baptiste PENRATH cdb4e207e5 ✨(backend) add auto labelling ai feature
When a message is received, if the auto labelling feature is enabled,
we try to add all relevant labels that are flagged for auto labelling to this
message.

Co-authored-by: jbpenrath <jb.penrath@gmail.com>
2025-08-19 23:48:03 +02:00
jbpenrath 014f60d3b8 ✨(front) header design v2
Add a new UserMenu component
2025-08-19 18:25:55 +02:00
jbpenrath 7d28398451 🚸(front) ask confirmation before label deletion
Ask user confirmation before deleting label to prevent miss click.
2025-08-19 17:08:37 +02:00
jbpenrath 2a3f8b748b 🚸(front) improve labels UX
Allow to drag'n'drop labels to reorder them.
Add an option to create a new label in the thread labels widget.
2025-08-14 17:22:37 +02:00
jbpenrath 4de994e990 💄(frontend) sidebar design v2
Revamp the sidebar application.
- New mailbox dropdown menu
- More spaced mailbox folders
- New labels design and edition form
2025-08-14 10:38:14 +02:00
jbpenrath e6bd2c5a37 🐛(frontend) invalidate properly mailbox query on mailbox creation
When an admin creates a new mailbox and there was on
the first page of the mailboxes, the data was not refreshed.
2025-08-13 16:55:59 +02:00
BastienandGitHub dfe7f7e4a0 (cron) add pgdump cron for keycloak deployment (#312)
adds the scalingo_pgdump.sh script for keycloak deployments
adds the cron.json to start the dump every night
2025-08-12 20:08:15 +02:00
jbpenrath cf66702adc ✨(front) paginate maildomain and mailboxes views
Add pagination on maildomain and mailboxes data grid to allow navigation
in large list of items
2025-08-12 14:04:38 +02:00
jbpenrath 53110862d6 ✨(front) manage abilities
Improve openapi schema to pass abilities to frontend properly.
Then through the useAbility hook, hide/disable actions.
It concerns actions to send messages, write messages, share
thread access, crud labels, crud maildomain mailboxes.
2025-08-07 10:39:23 +02:00
jbpenrath 522f23e3d7 ✨(front) add Yahoo! imap config discovery
We recently add the support of Yahoo imap import.
To ease import with this mail provider we store its imap configuration.
2025-08-06 11:01:33 +02:00
jbpenrath d0b2a66f08 🐛(frontend) draftBody can be null
There was an error in the openapi schema and we are not aware that
message.draftBody could be null so when it was the case, the frontend
throws an error when rendering the `MessageForm` component.
2025-08-06 10:12:36 +02:00
jbpenrath f68925b8bd ✨(frontend) render fields according to SCHEMA_CUSTOM_ATTRIBUTES_USER
In the personal mailbox form, we now render extra fields according to the
`SCHEMA_CUSTOM_ATTRIBUTES_USER` got through config endpoint.

Those fields are validated through zod and the schema is generated through
`zod-from-json-schema` package. Then a custom component is in charge to
render the right component according to the schema property `type`.
2025-08-06 10:12:36 +02:00
jbpenrath 4a311e5b3c ✨(backend) define custom_attributes through env vars json schema string
User and MailDomain have both `custom_attributes` json field. Those fields
aims to store extra data about those models specific to an instance. In order
to fulfill those fields with consistency and without requiring to fork the
project, we add two new settings `SCHEMA_CUSTOM_ATTRIBUTES_*`.
Those 2 settings expects a JSON Schema string defined through env vars.
Then on model save, those schema are used to validate data saved into
custom attributes.
2025-08-06 10:12:36 +02:00
jbpenrath 7a4022c95a ⬆️(frontend) migrate to zod 4
https://zod.dev/v4/changelog
2025-08-06 10:12:36 +02:00
Sylvain ZimmerandGitHub 5b9de7c4eb ♻️(services) refactor Services into a single directory (#304)
* 🐛(scalingo) add an env var to disable Celery beat scheduling

Deployments on fresh PaaS databases would fail because of this, without
giving the user the ability to create the database through a manual
run command.

* 🐛(nginx) fix error when no env vars configured

* ♻️(services) refactor Services into a single directory

I haven't done AI yet because there are pending patches but once done we'll also have core/services/ai/*.py
I used importer as a name to avoid using a Python keyword

* 🚨(lint) move imports to the top
2025-08-05 14:45:18 +02:00
jbpenrath f4638c5484 ✨(front) add mailbox settings dropdown menu
In the mailbox actions, add a mailbox settings dropdown menu
with an option to import messages.
2025-08-04 12:30:46 +02:00
jbpenrath 553e49c787 ✨(frontend) add user menu entry to administrate mail domains
If the user has required ability to view mail domains,
a menu entry is displayed.
2025-07-31 17:19:23 +02:00
jbpenrath 7c07711489 👽️(openapi) improve user definition with or without abilities
The OpenAPI Schema does not embedded abilities property.
We fix that and make two serializers for User model in order to get proper
openapi definition for User instance with abilities and without abilities.
2025-07-31 17:19:23 +02:00
Sabrina Demagny 64b9f96aa2 🐛(imap) handle missing Yahoo drafts import 2025-07-31 11:43:17 +02:00
jbpenrath 8eda2de14c ✨(front) add button to copy credential on mailbox creation
Add a button to quicly copy credentials when a new mailbox has
been copied.
2025-07-30 14:14:46 +02:00
jbpenrath 72484008be ✨(front) Allow to pick files from drive if set up.
Use the drive-sdk package to allow user to pick a file from its drive workspace
if one drive instance has been set up through envvars.

https://github.com/suitenumerique/drive
2025-07-30 13:57:04 +02:00
jbpenrath dbcc537618 ✨(front) add a useFeatureFlag hook
Add a hook to know if a feature is enabled or not
(AI Features, Interop Features, etc.)
2025-07-30 13:57:04 +02:00
jbpenrath a56ca6b113 ✨(backend) add settings to configure drive external service
We want to add ability to Messages to interop with our Drive application.
First, we want to be able to set the Drive base url through environment
variable then pass down Drive configuration to frontend through the config
api endpoint.

https://github.com/suitenumerique/drive
2025-07-30 13:57:04 +02:00
jbpenrath 4fa111b3e6 ✨(front) set max size attachment
Only allow to upload blob of 25MB as attachment
2025-07-30 13:57:04 +02:00
Sabrina Demagny c7fb77b737 ✨(frontend) remove max_messages and folder fields on imap import
Run 'make api-update'
2025-07-28 11:18:28 +02:00
Sabrina Demagny 6d6bbea0d9 ✨(imap) improve IMAP import code, load folders for GMAIL and ORANGE
- Load folders for GMAIL and ORANGE
- Fix read issue with Gmail IMAP import (all messages were marked as read)
- Fix IMAP encoding for Gmail import
- Refactor monolithic import_imap_messages_task into smaller, focused functions
- Add IMAPConnectionManager context manager for better resource management
- Extract helper functions with single responsibilities

This refactoring improves code maintainability, readability, and testability
while maintaining backward compatibility with existing API.
2025-07-28 11:18:28 +02:00
BastienandGitHub 3f1154a4b1 (cron) pgdump: fix restic repository. (#293) 2025-07-25 17:58:11 +02:00
jbpenrath ac99f78371 🐛(front) prevent input cursor to jump on update value
Fix an issue that cause the input cursor to jump when user
types in the combobox input
2025-07-25 16:32:08 +02:00
jbpenrath 60f24d166a ✨(front) add combobox to type mail recipients
Add a new combobox input to be to get an autocomplete when typing recipients.
2025-07-25 00:56:55 +02:00
Sabrina Demagny 03cd72f0fb 🐛(labels) support identical label slugs across different mailboxes
- Replace single label lookup with multiple labels filter in ThreadViewSet
- Allow filtering threads by label_slug across multiple mailboxes when user has access
- Expect empty results instead of 403 errors for inaccessible labels
- Add comprehensive tests for identical labels in different mailboxes scenarios

This change enables users with access to multiple mailboxes to filter threads
by label slug across all accessible mailboxes, while maintaining proper
permission checks and supporting mailbox-specific filtering.
2025-07-24 12:47:27 +02:00
Mathis ROUGETandJean-Baptiste PENRATH e32862e4b3 ✨(ai) add thread summary 2025-07-24 11:45:07 +02:00
Mathis ROUGETandJean-Baptiste PENRATH 796c51a7f9 ✨(frontend) add forgot attachment detection 2025-07-24 11:45:07 +02:00
Mathis ROUGETandJean-Baptiste PENRATH e08acda852 ✨(ai) setup ai service 2025-07-24 11:45:07 +02:00
BastienandGitHub 45d8c295c6 (cron) pgdump: add 30 days backup retention. (#288) 2025-07-23 10:48:54 +02:00
BastienandGitHub 0accafd979 ci: backup with restic instead of awscli. (#287) 2025-07-22 11:52:51 +02:00
Sabrina Demagny 65af318fb5 ✨(backend) add get_abilities for Mailbox
- Add pre-calculation of user access roles in MailboxViewSet list/retrieve methods
- Implement get_abilities method on Mailbox model for permission checking
- Add AbilitiesModelSerializer to MailboxSerializer for consistent abilities field
- Optimize database queries by reducing N+1 access lookups
- Add comprehensive test coverage for abilities and optimized queries

This optimization significantly reduces database queries when listing
mailboxes by pre-calculating user roles instead of querying for each
mailbox individually.
2025-07-22 09:34:09 +02:00
Sylvain ZimmerandGitHub 9b4ba9ba09 ✨(dns) add admin page for DNS records (#283)
* ✨(dns) add admin page for DNS records. Fixes #177

* 👷(dockerflow) add a flag to disable Dockerflow

* 💚(ghactions) fix check-api-update that was missing Orval

* 💚(ci) fix tests that depended on Keycloak

* ♻️(admin) refactor CopyableInput into a separate component

* 🎨(dns) improve code style
2025-07-21 14:41:08 +02:00