Hylafax to Email

# configure dispatch
cat < /etc/hylafax/FaxDispatch
SENDTO=YOU@YOUR_DOMAIN
FILETYPE=pdf
TEMPLATE=de
EOF

# configure postfix
postconf -e 'smtp_sasl_security_options = noanonymous'
postconf -e 'smtp_sasl_password_maps = hash:/etc/postfix/sasl_password'
postconf -e 'smtp_sasl_auth_enable = yes'
postconf -e 'relayhost = smtp'
echo "smtp faxmaster:faxmaster" > /etc/postfix/sasl_password
postmap /etc/postfix/sasl_password
/etc/init.d/postfix restart

# get sender name from url (optional)
cat < /etc/hylafax/FaxDispatch
SENDTO=YOU@YOUR.DOMAIN
FILETYPE=pdf
TEMPLATE=de
SENDER_NAME=`wget -q http://YOUR_SERVER/getName.php?fax=$CALLID1 -O -`
if [ ! -z "$SENDER_NAME" ]; then
SENDER=$SENDER_NAME
fi
EOF