Commit Graph

1071 Commits

Author SHA1 Message Date
cliffmccarthy
e708027edb feat: Remove obs-home-deltachat.gpg
- We don't install Dovecot from OBS anymore.
- Removed files.put() that creates
  /etc/apt/keyrings/obs-home-deltachat.gpg; replaced this with a
  files.file() that sets present=False to remove the file from any
  existing installations where it already has been installed.
- Removed now-unused obs-home-deltachat.gpg file.
- Clarified description of sources.list operation.
- Suggested in review by missytake and hpk42.
2025-11-08 10:16:35 -06:00
cliffmccarthy
27b72039c8 fix: Block unbound from starting up on install
- On an IPv4-only system, if unbound is started but not configured, it
  causes subsequent steps to fail to resolve hosts.
- Revised UnboundDeployer.install_impl() to use policy-rc.d to prevent
  the service from starting when installed.  This is the same
  mechanism used to keep nginx from starting on install.
2025-11-08 10:16:35 -06:00
cliffmccarthy
32534251bf docs: Add architectural information about deployer classes
- Updated ARCHITECTURE.md to describe the Deployer class hierarchy and
  the motivations behind it.
2025-11-08 10:16:35 -06:00
cliffmccarthy
1a03d56c80 refactor: Call install, configure, and activate methods in loops
- Revised deploy_chatmail() to use all_deployers to call the
  install(), configure(), and activate() methods on all the deployers,
  rather than listing them explicitly in the code.
2025-11-08 10:16:35 -06:00
cliffmccarthy
e043c1baff refactor: Reorder deploy_chatmail()
- The previous commits that added Deployer classes mostly kept
  deployment operations in the same order that they were in before.
  To organize the process into separate stages for install, configure,
  and activate, we need to reorder the method calls.  This is the
  commit that does that, and thus this is the commit that has the
  largest effect on the order of operations.
- The calls for the deployer objects are all reordered here so that
  the methods are called in the same sequence for each stage.  This
  will allow us to collect the calls into loops in the next commit.
  This commit provides a way to see a diff showing exactly how the
  sequence changed.
- The sequence of deployers was largely based on preserving the order
  of the "activate" stage, as this seems like the place order might be
  the most likely to matter.  Installation of packages and
  configuration of files should generally be able to run in any order.
  (ChatmailDeployer handles updating the apt data, and therefore needs
  to be first, however.)
2025-11-08 10:16:35 -06:00
cliffmccarthy
a9d3709663 refactor: Move curl installation from IrohDeployer to ChatmailDeployer
- The 'curl' program is used in TurnDeployer and IrohDeployer, so it
  makes more sense to install it at the beginning in ChatmailDeployer,
  rather than have each thing that uses it install it separately.
2025-11-08 10:16:35 -06:00
cliffmccarthy
741948682f refactor: Add TurnDeployer
- This splits the existing deploy_turn_server() routine into methods
  for the install, configure, and activate stages.
2025-11-08 10:16:35 -06:00
cliffmccarthy
68b78bf6d2 refactor: Add WebsiteDeployer
- This adds a step to create /var/www in the install stage, because
  the directory needs to exist for the rsync in the configure stage to
  work.
2025-11-08 10:16:35 -06:00
cliffmccarthy
0e756c653d refactor: Add EchobotDeployer
- This class is a special case because it has a dependency on the
  Postfix and Dovecot deployers.  When deciding whether to restart the
  echobot service, it needs to know whether the Postfix and Dovecot
  deployers restarted their services.  To support this dependency, the
  PostfixDeployer and DovecotDeployer objects are passed to the
  EchobotDeployer object, so it can check their was_restarted
  attributes.
2025-11-08 10:16:35 -06:00
cliffmccarthy
69de709b0f refactor: Add FcgiwrapDeployer 2025-11-08 10:16:35 -06:00
cliffmccarthy
d11163629b refactor: Add ChatmailDeployer
- This moves the installation of cron earlier in the deployment sequence.
2025-11-08 10:16:35 -06:00
cliffmccarthy
e92c8766f6 refactor: Add ChatmailVenvDeployer 2025-11-08 10:16:35 -06:00
cliffmccarthy
334e468889 refactor: Split _install_remote_venv_with_chatmaild into stages
- Split _install_remote_venv_with_chatmaild() into three routines, to
  handle the install, configure, and activate stages.
- This moves the upload of chatmail.ini later in the deployment
  process, because it is a configuration file specific to the
  instance, not software installation that would be uniform across all
  deployments.
2025-11-08 10:16:35 -06:00
cliffmccarthy
33e6807ca4 refactor: Add RspamdDeployer
- This replaces the existing _remove_rspamd() routine with a method
  for the install stage.
2025-11-08 10:16:35 -06:00
cliffmccarthy
2029acc5a9 refactor: Add MtastsDeployer
- This splits the existing _uninstall_mta_sts_daemon() routine into
  methods for the configure and activate stages.
2025-11-08 10:16:35 -06:00
cliffmccarthy
d1788b7c65 refactor: Add MtailDeployer
- This splits the existing deploy_mtail() routine into methods for the
  install, configure, and activate stages.
2025-11-08 10:16:35 -06:00
cliffmccarthy
84ab4bb6b8 refactor: Add AcmetoolDeployer
- This splits the existing deploy_acmetool() routine into methods for
  the install, configure, and activate stages.
2025-11-08 10:16:35 -06:00
cliffmccarthy
04451ad537 refactor: Add JournaldDeployer 2025-11-08 10:16:35 -06:00
cliffmccarthy
d09a118e54 refactor: Add IrohDeployer
- This splits the existing deploy_iroh_relay() routine into methods
  for the install, configure, and activate stages.
2025-11-08 10:16:35 -06:00
cliffmccarthy
5b982a3b0f refactor: Add UnboundDeployer 2025-11-08 10:16:35 -06:00
cliffmccarthy
71636b8250 refactor: Add OpendkimDeployer
- Note that this moves the installation of the opendkim package
  earlier in the deployment sequence.  Previously, it was installed
  during the _configure_opendkim() routine.
2025-11-08 10:16:35 -06:00
cliffmccarthy
e7df1a43a3 refactor: Add NginxDeployer
- Use policy-rc.d during nginx install.  This is needed to keep nginx
  from starting up and interfering with acmetool.  For more information see:
    - https://serverfault.com/questions/861583/how-to-stop-nginx-from-being-automatically-started-on-install
    - https://major.io/p/install-debian-packages-without-starting-daemons/
    - https://people.debian.org/~hmh/invokerc.d-policyrc.d-specification.txt
2025-11-08 10:16:35 -06:00
cliffmccarthy
cfc94a37b3 refactor: Add PostfixDeployer
- Removed now-unused 'debug' variable from deploy_chatmail().
2025-11-08 10:16:35 -06:00
cliffmccarthy
22b77168ed refactor: Add DovecotDeployer 2025-11-08 10:16:35 -06:00
cliffmccarthy
ffcd657a88 refactor: Add Deployer base class
- Added a Deployer class that defines the base for objects that will
  handle installation of individual components, with install,
  configure, and activate stages.  Subclasses will override the
  implementation methods of those stages as needed, while the base
  class handles all the logic of deciding which stages to execute.
- The CMDEPLOY_STAGES environment variable is used to determine what
  stages to run.  If this is not defined, all stages run as usual.
- Added import of Deployer to cmdeploy/__init__.py.  This is not yet
  used, but the next series of commits will use it.
- In deploy_chatmail(), define an empty list of deployers, and call
  the create_groups() and create_users() methods for the items in the
  list.  This list will get filled with Deployer objects in the next
  series of commits.
2025-11-08 10:16:35 -06:00
cliffmccarthy
39fd04473c refactor: Move addition of 9.9.9.9 resolver earlier
- Moved the "Add 9.9.9.9 to resolv.conf" step earlier, before the
  creation of users or updates to any config files.  This should not
  affect any of those operations.  Moving this step earlier makes it
  easier to accommodate the restructuring of the deployment process
  into separate components with separate stages for install,
  configure, and activate.
2025-11-08 10:16:35 -06:00
cliffmccarthy
49613f7e71 refactor: Move all imports to top of cmdeploy/__init__.py 2025-11-08 10:16:35 -06:00
missytake
ded9dd470d www: add changelog 2025-11-06 16:19:02 +01:00
Alexander
b94ad729fd Update cmdeploy/src/cmdeploy/__init__.py
Co-authored-by: missytake <missytake@systemli.org>
2025-11-06 16:17:12 +01:00
Alexander Dietrich
b60267f37f Skip www_folder if merge conflict marker found 2025-11-06 16:17:12 +01:00
missytake
a0aa2912dd ci: fix test methods for deltachat 2.23.0 2025-11-06 12:33:59 +01:00
Serge Matveenko
76108c1c03 Test dig output with dns comments 2025-11-06 11:26:02 +01:00
Serge Matveenko
61b8dc4637 Improve dns responses parsing 2025-11-06 11:26:02 +01:00
Lars-Dominik Braun
d42f579291 turnserver: Strip newline from response. 2025-11-03 22:57:43 +00:00
Serge Matveenko
dd3cf4d449 Update dovecot-core deb sha256 sums 2025-10-30 11:23:19 +01:00
holger krekel
7361cc9350 fix changelog references 2025-10-29 13:33:25 +01:00
missytake
00f199816d unpublish mutual help group invite link 2025-10-28 16:12:07 +01:00
link2xt
8d7e1dad0e Require STARTTLS for incoming port 25 connections
We already require that outgoing connections
use STARTTLS so other servers need a valid TLS
certificate to accept messages from us.
It is then very unlikely that they cannot use TLS
to send messages to us.

Conversely, if they only can send messages to use without TLS,
it likely does not have STARTLS on its port 25
and then we don't want to accept messages from them
because we will likely not be able to reply.
2025-10-28 01:44:14 +00:00
link2xt
c0da7bb3bf docs: chatmail-turn listens on 3478 UDP, not TCP port 2025-10-28 01:08:06 +00:00
holger krekel
863ded6480 try to limit index cache max size 2025-10-28 01:42:37 +01:00
missytake
d75321b355 doc: write down some basic infos on chatmail-turn (#693)
Co-authored-by: l <link2xt@testrun.org>
2025-10-27 09:00:07 +01:00
link2xt
9148b16d81 acmetool: use ECDSA keys instead of RSA 2025-10-25 08:00:31 +00:00
holger krekel
fa9aa5b015 guard expire/fsreport file iteration against vanishing, improve reporting
also activates actual deletion (after quite some dry test runs on nine)
2025-10-22 20:30:12 +02:00
link2xt
0155f32df6 Require TLS 1.2 for outgoing SMTP connections 2025-10-22 02:46:29 +00:00
holger krekel
9ddd5d8b2b Replace expiry "find" commands with a new chatmaild.expire python module + a reporting one 2025-10-21 20:50:46 +00: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