~control/dirmaker

From Qmail-LDAP Wiki

Jump to: navigation, search

Absolute path to your program/script that creates missing homedirs.

Default:

none (off)

Example:

/var/qmail/bin/create_homedir

Notes:

  • The script is executeded after the setuid/gid, it isn't running under root for security reasons.
  • The command is executed with execve not system (so mkdir --mode=700 -p does not work!) use a shell script.
  • $1 is the homedir-path and $2 is aliasempty.
  • If you use $2 have a look at the first and last char to ensure that it is a path to the maildir and not a pipe or mailbox delivery.

Example of very simple shell script:

#!/bin/sh
mkdir -m 700 -p $1
#EOF
Personal tools