Skip to content
Snippets Groups Projects
Commit 29a5afb1 authored by Florent Thiery's avatar Florent Thiery
Browse files

send mail to non existing address, fixes #20590

parent 195ba793
No related branches found
No related tags found
No related merge requests found
......@@ -2,14 +2,15 @@
# Copyright 2017, Florent Thiery
# envoyer un mail contenant un truc random
RAND="$RANDOM"
EMAIL="deployment+$RAND@ubicast.eu"
EMAIL="noreply+$RAND@ubicast.eu"
echo "Sending email to $EMAIL"
echo "This is a test email" | mail -s "Test email from `cat /etc/hostname`" $EMAIL
sleep 10
grep $EMAIL /var/log/mail.log | grep bounced > /dev/null
if [ $? -e 0 ]; then
if [ $? -eq 0 ]; then
echo "Sending mail failed"
exit 1
fi
echo "Sending mail succeeded"
exit 0
# check un webservice qui recoit le mail
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment