Skip to content

Instantly share code, notes, and snippets.

@aredridel
Created August 4, 2017 05:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save aredridel/4de77c15f609d531b8d01ca511b9d455 to your computer and use it in GitHub Desktop.
Save aredridel/4de77c15f609d531b8d01ca511b9d455 to your computer and use it in GitHub Desktop.
Complete opensmtpd config to make a server just archive everything it receives. Requires a user named archive to be present on the system and own that directory.
listen on ::
table aliases file:/etc/aliases
table anyone { "@" = archive }
accept for local alias <aliases> deliver to mbox
accept from any for any virtual <anyone> deliver to maildir "/var/lib/archive/%{rcpt:lowercase|strip}"
@aredridel
Copy link
Author

The equivalent postfix configuration is a half dozen files, a scattered assortment of directives, and requires abusing the primitives provided.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment