[sf-perl] hostid in mac os x?

David Alban extasia at extasia.org
Sat Jan 5 19:09:56 PST 2008


Reference:  http://mail.pm.org/pipermail/sanfrancisco-pm/2006-December/000814.html
and followups

i haven't used my module on a mac since then, but i now want to do so.
 fyi, my solution:  create /usr/local/bin/hostid, which contains:

    #!/bin/bash

    export PATH=/sbin:/bin:/usr/sbin:/usr/bin

    ifconfig en0 | grep ether | awk '{ print $2 }' | sed 's/://g'

i want a hostid because there's a routine in my module which sends
email, and i add an 'X-Hostid' header to each message.

-- 
Live in a world of your own, but always welcome visitors.


More information about the SanFrancisco-pm mailing list