Hello Tiger

Computing

I had to replace my home server’s [broken Ubuntu][1]. It is an ancient Mac Cube, so going back to MacOSX Tiger seemed like the easiest thing to do.

Using MacPorts, I installed Apache2, SVN, SSL etc.

With a WebDAV repository setup, I needed a way to broadcast it’s URL over the local subnet using Bonjour, ironically for a Mac there did not seem to be a way to do it.

MacOS Client comes with a Bonjour Module for Apache 1.3, MacOSX Server comes with one for Apache2 (but I do not have it). Linux can use mod_dnssd but as it is based on Avahi, I am pretty sure it won’t work on MacOSX.

A bit of Googling and I found the dns-sd command. The man page says it is designed for testing only, but it seems to work fine, fired off once at startup.

I use this plist, placed in /Library/LaunchDaemons/

[1]: {% post_url 2007-10-21-grotty-gibbon %}

    <?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>Debug</key>
     <false/>
     <key>Label</key>
     <string>org.fiveone.shared-dav-dns-sd</string>
     <key>OnDemand</key>
     <false/>
     <key>ProgramArguments</key>
     <array>
      <string>/usr/bin/dns-sd</string>
      <string>-R</string>
      <string>Shared-DAV</string>
      <string>_webdav._tcp</string>
      <string>local</string>
      <string>80</string>
      <string>path=/Shared/</string>
     </array>
     <key>RunAtLoad</key>
     <true/>
     <key>ServiceDescription</key>
     <string>Bonjour Shared</string>
    </dict>
    </plist>