[] add short outline document hs-archive-transport
authorHeiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Mon, 2 Jan 2017 15:27:46 +0000 (16:27 +0100)
committerHeiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Fri, 20 Jan 2017 17:27:18 +0000 (18:27 +0100)
doc/doc-txt/experimental-archive [new file with mode: 0644]

diff --git a/doc/doc-txt/experimental-archive b/doc/doc-txt/experimental-archive
new file mode 100644 (file)
index 0000000..325298d
--- /dev/null
@@ -0,0 +1,78 @@
+As soon as the message is spooled (positive response to the sender),
+we need to archive it.
+
+    - message
+    - metadata (envelope)
+    - message logs
+
+There needs to be an external archiver, this may be a process, or a
+simple directory. A transport? Key is the $message_exim_id
+
+The external process needs to be prepared to get multiple
+chunks of data, in a simple stream format:
+
+    <id> <type>
+    <data>
+
+e.g.
+    message:1cTjg6-0002kS-Lb
+    …
+    … (header and body of the message
+
+    log:1cTjg6-0002kS-Lb
+    …
+    … (log lines
+
+    completed:1cTjg6-0002kS-Lb
+
+If we store into external files, then mbx format,
+with a fixed(?) local_part. (or flexible (message_exim_id)?)
+
+    From …
+    [original message in mbx format]
+
+    From …
+    Subject:
+
+
+Maybe an event msg:spooled can be used.
+
+--
+
+* set some archive-bit during ACL phase
+
+* keep the message around as long as not archived
+* same for the message logs
+* archiving is a normal "transport", selected
+  via "archive_transport" main config option
+
+* Or - use a router to add a "archive" address, something like
+  always-bcc other have
+
+# exim config
+
+begin acl
+
+
+    ..
+
+        control = archive
+
+begin routers
+
+    dnslookup:
+        driver = dnslookup
+        transport = remote_smtp
+        archive_transport = archive
+
+    local_user:
+        driver = accept
+        transport = appendfile
+        archive_transport = archive
+
+begin transports
+
+    archive:
+        driver = appendfile
+        file = /var/mail/ARCHIVE/archive.mbx
+