offlineimap - use ssh preauthtunnel
add script to keep up smtptunnel
get rid of smtptunnel script
use ssh to sendmail command to send aptivate email

In the authorized_keys files we have:

command="/usr/sbin/sendmail -bm -t -oem -oi",no-X11-forwarding,no-agent-forwarding,no-port-forwarding,no-pty ssh-dss AAAA...

Which works for exim at least