holger krekel
0931da21b8
make sure fsreport can run on empty mailbox dir
2025-10-21 18:43:37 +02:00
holger krekel
11a8f8cf9e
try fix CI
2025-10-21 18:43:37 +02:00
holger krekel
0aa255e3f1
replace expunge mentioning in architecture
2025-10-21 18:43:37 +02:00
holger krekel
6c4764b452
Apply suggestions from code review
...
fix typo
Co-authored-by: l <link2xt@testrun.org >
2025-10-21 18:43:37 +02:00
holger krekel
c1f08a9afe
simplify and beautify formatting and sizes
2025-10-21 18:43:37 +02:00
holger krekel
5c8afb377e
also run fsreport
2025-10-21 18:43:37 +02:00
holger krekel
8225a9f398
use systemd timer instead of cron-job for expiry (tested by hand on c2)
2025-10-21 18:43:37 +02:00
holger krekel
eb221ca1af
unify K output
2025-10-21 18:43:37 +02:00
holger krekel
93421b317b
always use "H" for printing numbers, and make "chatmail.ini" file optional, defaulting to where it is on chatmail relays
2025-10-21 18:43:37 +02:00
holger krekel
777be107f3
fix another invocation
2025-10-21 18:43:37 +02:00
holger krekel
8b81d5b5d6
unify chatmail-fsreport and chatmail-expire to both just require a chatmail.ini file
2025-10-21 18:43:37 +02:00
holger krekel
e6a2906e82
cosmetic: refine summary and fix typo
2025-10-21 18:43:37 +02:00
holger krekel
67ba4ac99e
address four review comments from link2xt
2025-10-21 18:43:37 +02:00
holger krekel
8cadf51387
prefix new commands
2025-10-21 18:43:37 +02:00
holger krekel
ce4bb97294
remove superflous totalsize attribute
2025-10-21 18:43:37 +02:00
holger krekel
3a0c629f3b
during fsreport (reporting) don't store all mailbxoes but categorize them immediately, provide a few command line options to select
2025-10-21 18:43:37 +02:00
holger krekel
8df53c2655
fix lint issues
2025-10-21 18:43:37 +02:00
holger krekel
3fd3ab1a68
some renaming
2025-10-21 18:43:37 +02:00
holger krekel
d74f792787
remove superflous Stats class
2025-10-21 18:43:37 +02:00
holger krekel
1135372b81
further reduce code
2025-10-21 18:43:37 +02:00
holger krekel
c9f80bffd8
no reporting by default, and adding a summary line
2025-10-21 18:43:37 +02:00
holger krekel
10e53d17e8
don't globally collect files anymore to avoid using growing-with-number-of-mailboxes ram
2025-10-21 18:43:37 +02:00
holger krekel
01ca2a8b91
more streamline
2025-10-21 18:43:37 +02:00
holger krekel
fb01944f0d
strike superflous code
2025-10-21 18:43:37 +02:00
holger krekel
a90a651ba0
fix comment
2025-10-21 18:43:37 +02:00
holger krekel
7d74b46502
add argument parsing for reporting
2025-10-21 18:43:37 +02:00
holger krekel
6d3e690653
add basic command line parsing for expire + some streamlining
2025-10-21 18:43:37 +02:00
holger krekel
ed7a70ba31
refactor and write tests for overall expiry/report runs
2025-10-21 18:43:37 +02:00
holger krekel
023116bc91
add summary reporting, rework expiry logic
2025-10-21 18:43:37 +02:00
holger krekel
b13929119b
do all expunging in python
2025-10-21 18:43:37 +02:00
holger krekel
a4152140ca
move delete_inactive_users to new implementation
2025-10-21 18:43:37 +02:00
missytake
4cfe228a1f
filtermail: further optimize check_armored_payload()
2025-10-21 00:57:27 +02:00
holger krekel
741a20450c
Add a system test for running the filtermail module
2025-10-20 19:02:14 +00:00
adb
b7fadcd4be
filtermail: improve check_armored_payload() ( #679 )
2025-10-20 09:55:53 +02:00
missytake
7db26f33d9
nginx: be more specific with the server name ( #636 )
2025-10-19 14:02:41 +02:00
link2xt
2b90f7db37
filtermail: run CPU-intensive handle_DATA in a thread pool executor
...
See
<https://docs.python.org/3/library/asyncio-eventloop.html#executing-code-in-thread-or-process-pools >
for the documentation.
This should avoid processing of large messages from hogging asyncio
thread and delaying async operations like accepting new connections.
2025-10-19 10:43:11 +00:00
holger krekel
e37dd5153a
remove logging and just print to sys.stderr
2025-10-18 19:50:13 +00:00
missytake
f21e4ff55b
opendkim: increase DNSTimeout from 5 (default) to 60
...
fix #667
2025-10-17 11:27:18 +02:00
cliffmccarthy
21258a267a
test: Handle Git errors in test_deployed_state()
...
- This is a counterpart to pull request #607 . Revised
test_deployed_state() to perform the same error-handling on Git
commands that cmdeploy does. If 'git rev-parse' returns an error,
the value "unknown" is used. If 'git diff' returns an error, the
null string is used.
- This fixes failures in environments where Git is not installed or
where the .git subdirectory is not present (as long as the server
was deployed in the same way).
2025-10-16 16:15:35 +02:00
missytake
e7ddf6dc32
cmdeploy: make --ssh-host expect '@docker' instead of 'docker'
2025-10-14 22:27:02 +02:00
missytake
e3c77a5b37
cmdeploy: introduce LocalExec object
2025-10-14 22:27:02 +02:00
missytake
8256080ad1
Revert "tests: first attempt to mock shell() call"
...
This reverts commit a0c632a7006a83c8b39cff86228296c32c5c5b9e.
2025-10-14 22:27:02 +02:00
missytake
248b225665
tests: first attempt to mock shell() call
2025-10-14 22:27:02 +02:00
missytake
79591adca4
cmdeploy: prepare for being able to run commands in docker containers
2025-10-14 22:27:02 +02:00
missytake
185757cf40
tests: disable failing stderr capturing in test_logged for now
2025-10-14 22:27:02 +02:00
missytake
87a3adec03
cmdeploy: allow to run SSH commands locally
...
fix #604
related to #629
pulled out of https://github.com/Keonik1/relay/pull/3
2025-10-14 22:27:02 +02:00
cliffmccarthy
4f5719f590
test: Add retries to test_rewrite_subject() ( #670 )
...
- test_rewrite_subject() is prone to failure when it checks for the
delivered message, because fetch_all_messages() raises "ValueError:
no messages in imap folder". The check has the potential to happen
before the server has had a chance to deliver the message to the
user's inbox.
- Added a function try_n_times() that attempts to call a function the
specified number of times, with a 1-second sleep between calls. The
call is retried until it doesn't raise an exception. The last call
is made without a 'try' block, so that the final exception passes
through to the caller if it does not return.
- Wrapped call to fetch_all_messages() in try_n_times(), with 5
attempts specified. This should usually allow enough time for the
message to get moved from the postfix queue to the user's inbox.
2025-10-14 21:18:15 +02:00
cliffmccarthy
9787b63cbb
test: Return None for success in test_timezone_env() ( #671 )
...
- test_timezone_env() is producing the warning,
"PytestReturnNotNoneWarning: Test functions should return None, but
src/cmdeploy/tests/online/test_1_basic.py::test_timezone_env
returned <class 'bool'>".
- Revised test_timezone_env() to return None for success instead of
True.
2025-10-14 21:17:56 +02:00
missytake
6f600fa329
config: add www_folder to default config ( #634 )
2025-10-14 21:17:08 +02:00
missytake
20b6e0c528
www: chown /var/www/html to www-data
2025-10-14 21:16:49 +02:00