aboutsummaryrefslogtreecommitdiff
path: root/src/property/postfix.lisp
diff options
context:
space:
mode:
Diffstat (limited to 'src/property/postfix.lisp')
-rw-r--r--src/property/postfix.lisp13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/property/postfix.lisp b/src/property/postfix.lisp
index a33bbbd..82a2ae2 100644
--- a/src/property/postfix.lisp
+++ b/src/property/postfix.lisp
@@ -55,3 +55,16 @@ defaults to the first argument to PROPAPP."
(apply f args))
(file:does-not-exist (strcat (unix-namestring file) ".db")))
:args (cdr propapp)))
+
+(defproplist daemon-socket-directory :posix
+ (daemon-user &optional (daemon-group daemon-user) (name daemon-user)
+ &aux (dir (ensure-directory-pathname
+ (merge-pathnames name #P"/var/spool/postfix/"))))
+ "Create directory NAME in /var/spool/postfix in which a daemon can create a
+Unix domain socket for communication with Postfix. Commonly used for milters
+like OpenDKIM, OpenDMARC, etc.."
+ (:desc #?"Postfix daemon socket directory created for ${daemon-user}")
+ (installed)
+ (file:directory-exists dir)
+ (file:has-ownership dir :user daemon-user :group daemon-group)
+ (file:has-mode dir #o750) (user:has-groups "postfix" daemon-group))