mirror of
https://github.com/chatmail/relay.git
synced 2026-05-11 00:14:36 +00:00
Compare commits
5 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
6d3ffd8f4e | ||
|
|
a24f1e8393 | ||
|
|
f84692a07a | ||
|
|
4badc7c8d6 | ||
|
|
4b82fd6f77 |
59
README.md
59
README.md
@@ -4,7 +4,58 @@ This package deploys Postfix and Dovecot servers, including OpenDKIM for DKIM si
|
||||
|
||||
Postfix uses Dovecot for authentication as described in <https://www.postfix.org/SASL_README.html#server_dovecot>
|
||||
|
||||
## Ports
|
||||
## Getting started
|
||||
|
||||
prepare:
|
||||
|
||||
pip install -e chatmail-infra
|
||||
|
||||
|
||||
then run with pyinfra command line tool:
|
||||
|
||||
CHATMAIL_DOMAIN=c1.testrun.org pyinfra --ssh-user root c1.testrun.org deploy.py
|
||||
|
||||
|
||||
## Structure (wip)
|
||||
```
|
||||
|
||||
# package doveauth tool and deploy chatmail server to a envvar-specified ssh-reachable host
|
||||
deploy.py
|
||||
|
||||
# chatmail pyinfra deploy package
|
||||
chatmail-pyinfra
|
||||
pyproject.toml
|
||||
chatmail/__init__ ...
|
||||
|
||||
# tests against the deployed system
|
||||
tests/test_online_test.py
|
||||
|
||||
# doveauth tool used by dovecot's auth mechanism on the host system
|
||||
doveauth
|
||||
README.md
|
||||
pyproject.toml
|
||||
doveauth.py
|
||||
doveauth.lua
|
||||
test_doveauth.py
|
||||
|
||||
# lmtp server to block (outgoing) unencrypted messages
|
||||
filtermail
|
||||
README.md
|
||||
pyproject.toml
|
||||
....
|
||||
|
||||
|
||||
# scripts for setup/development/deployment
|
||||
|
||||
scripts/
|
||||
init.sh # create venv/other perequires
|
||||
deploy.sh # run pyinfra based deploy of everything
|
||||
|
||||
```
|
||||
|
||||
## Dovecot/Postfix configuration
|
||||
|
||||
### Ports
|
||||
|
||||
Postfix listens on ports 25 (smtp) and 587 (submission) and 465 (submissions).
|
||||
Dovecot listens on ports 143(imap) and 993 (imaps).
|
||||
@@ -12,9 +63,3 @@ Dovecot listens on ports 143(imap) and 993 (imaps).
|
||||
## DNS
|
||||
|
||||
For DKIM you must add a DNS entry as in /etc/opendkim/selector.txt (where selector is the opendkim_selector configured in the chatmail inventory).
|
||||
|
||||
## Run with pyinfra
|
||||
|
||||
```
|
||||
CHATMAIL_DOMAIN=c1.testrun.org pyinfra --ssh-user root c1.testrun.org deploy.py
|
||||
```
|
||||
|
||||
39
plan.txt
Normal file
39
plan.txt
Normal file
@@ -0,0 +1,39 @@
|
||||
# Chat-mail server development (up until Oct 18th)
|
||||
|
||||
## Dovecot goals/steps
|
||||
|
||||
1. create-user-on-login ("doveauth")
|
||||
- repackage so that "doveauth" does not come from a hard-coded path
|
||||
- persistence of accounts
|
||||
|
||||
2. per-user quota (adaptive)
|
||||
|
||||
3. automatic expiry of messages older than M days
|
||||
|
||||
4. automatic expiry of users that haven't logged in for N days
|
||||
|
||||
|
||||
## Postfix goals/steps
|
||||
|
||||
1. block all outgoing mails with our own LMTP program
|
||||
|
||||
2. only allow (outgoing) mails if secure-join or autocrypt-pgp-encrypted format
|
||||
(probably via an lmtp service)
|
||||
|
||||
3. basic outgoing send rate/limits (depending on "account-rating")
|
||||
|
||||
|
||||
## online tests (first with plain python/pytest)
|
||||
|
||||
- write tests for dovecot login (exists)
|
||||
- write tests for postfix logins
|
||||
- write A<>B send/receive tests
|
||||
|
||||
|
||||
## Delta Chat
|
||||
|
||||
1. qr code that defines access to a chatmail instance (like mailadm but without http etc.)
|
||||
|
||||
2. support for creating username/password and verifying login works
|
||||
|
||||
|
||||
3
scripts/deploy.sh
Executable file
3
scripts/deploy.sh
Executable file
@@ -0,0 +1,3 @@
|
||||
#!/usr/bin/env bash
|
||||
export CHATMAIL_DOMAIN="${1:-c1.testrun.org}"
|
||||
chatmail-pyinfra/venv/bin/pyinfra --ssh-user root "$CHATMAIL_DOMAIN" deploy.py
|
||||
4
scripts/init.sh
Executable file
4
scripts/init.sh
Executable file
@@ -0,0 +1,4 @@
|
||||
#!/bin/sh
|
||||
python3 -m venv chatmail-pyinfra/venv
|
||||
chatmail-pyinfra/venv/bin/pip install pyinfra
|
||||
chatmail-pyinfra/venv/bin/pip install -e chatmail-pyinfra
|
||||
Reference in New Issue
Block a user