On Mar 6, 2006, at 1:40 AM, Mark Crispin wrote:

I don't know much about launchd, other than the fact that it uses XML (shudder) and follows Apple's typical contempt of standards.

Oh please! What standards? If there's a uniform and performant solution that addresses system-init, network daemon listers, system- and per-user time-scheduled execution and the like, can we have a link to it? It was precisely this void that prompted Apple to create launchd.

Branding Apple as contemptuous of standards is rich indeed from the author of a distribution that hard-codes configuration settings in deeply-buried source files. What happened to the de-facto standard of using runtime configuration files like dhcpd, BIND, postfix, and Apache do? Never have I needed to repeatedly put configuration items in their source files (nor recompile to change them!) and their settings persist with almost no effort on my part from one release to the next.

But more broadly, when I "don't know much about" something I make an effort to learn about it before criticizing. To that end, there is readily-available information on launchd <http://developer.apple.com/ macosx/launchd.html>.

imapd and ipop3d do no TCP I/O on their own. All their I/O is via stdio; thus they are always invoked by the system's TCP listener (inetd or xinetd or launchd).

I build it using the OS X (PAM) target:
        make oxp

and copy the 2 executables:
sudo cp ./imapd/imapd /usr/local/sbin/ ; sudo chown root:wheel /usr/ local/sbin/imapd sudo cp ./ipopd/ipop3d /usr/local/sbin/ ; sudo chown root:wheel /usr/ local/sbin/ipop3d

(BTW, to make SSL mean much, one should procure a server certificate. With just a few clients even a self-signed one is manageable.)

I use two launchd .plist files: /Library/LaunchDaemons/ edu.washington.<imapd | pop3d>.plist. Each handles the plain and ssl form of the service. Here's my imap one:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http:// www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
  <key>Disabled</key>
    <false/>
  <key>Label</key>
    <string>edu.washington.imapd</string>
  <key>ServiceDescription</key>
    <string>IMAP Server</string>
  <key>ProgramArguments</key>
    <array>
      <string>/usr/local/sbin/imapd</string>
    </array>
  <key>inetdCompatibility</key>
    <dict>
      <key>Wait</key>
        <false/>
    </dict>
  <key>Sockets</key>
    <dict>
      <key>plain</key>
        <dict>
          <key>SockServiceName</key>
            <string>imap</string>
          <key>SockType</key>
            <string>stream</string>
        </dict>
      <key>ssl</key>
        <dict>
          <key>SockServiceName</key>
            <string>imaps</string>
          <key>SockType</key>
            <string>stream</string>
        </dict>
  </dict>
</dict>
</plist>


Best regards,
Mike Cashwell

_______________________________________________
Imap-uw mailing list
[email protected]
https://mailman1.u.washington.edu/mailman/listinfo/imap-uw

Reply via email to