#!/bin/sh
SHELL=/bin/sh
PATH=/bin:/usr/sbin
MAILTO=postmaster
SMARTHOST="xyz.zyx.de"

echo "es wird gefetched"

su -l susi   -c "fetchmail -v -f /home/susi/.fetchmailrc   >> /var/log/fetchlogs/susi-fetch.log"
su -l albert -c "fetchmail -v -f /home/albert/.fetchmailrc >> /var/log/fetchlogs/albert-fetch.log"
su -l karl   -c "fetchmail -v -f /home/karl/.fetchmailrc   >> /var/log/fetchlogs/karl-fetch.log"
su -l hanne  -c "fetchmail -v -f /home/hanne/.fetchmailrc  >> /var/log/fetchlogs/hanne-fetch.log"
su -l peter  -c "fetchmail -v -f /home/peter/.fetchmailrc  >> /var/log/fetchlogs/peter-fetch.log"
su -l hulufu -c "fetchmail -v -f /home/hulufu/.fetchmailrc >> /var/log/fetchlogs/hulufu-fetch.log"

echo "fetch Ende"

postfix flush

echo geflutscht!
