Launchd plist file

This file is for Mac OS X 10.4 and later. For 10.3 and earlier StartupItems must be used.

Save it under /Library/LaunchDaemons/ with .plist extension (e.g. org.dovecot.dovecot.plist, following naming conventions of Apple and other vendors). Ownership should be root:wheel.

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "">
<plist version="1.0">
     <string>Dovecot mail server</string>

If dovecot is not started as a foreground process, launchd will keep restarting it until the “No authentication sockets found” error message shows up in the logs and further logins are denied.