Hi all.
Something wrong with Entware Transmission.
I have a script in /jffs/scripts:
I have Entware Transmission installed and configured settings.json to include:
Everything was fine till a few days ago.
All script stop working!
A manual calling tmail.sh sends an e-mail but it does not work automatically!
No changes were done in system and/or configs before this happened.
Any idea what is wrong?
Something wrong with Entware Transmission.
I have a script in /jffs/scripts:
#!/bin/sh
FROM="g***@gmail.com"
AUTH="g***@gmail.com"
PASS="***"
FROMNAME="HSH"
TO="g***@gmail.com"
torrent_name="$TR_TORRENT_NAME"
torrent_version="$TR_APP_VERSION"
logger -t "$0" "Mail sent, about "$TR_TORRENT_NAME""
echo MIME-Version: 1.0 >/tmp/tmail.html
echo Content-Type: text/html >>/tmp/tmail.html
echo "Subject: Download notification" >>/tmp/tmail.html
echo "From: \\"$FROMNAME\\"<$FROM>" >>/tmp/tmail.html
echo "Date: `date -R`" >>/tmp/tmail.html
echo "" >>/tmp/tmail.html
echo "<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">" >>/tmp/tmail.html
echo "<html>" >>/tmp/tmail.html
echo "<head><title></title>" >>/tmp/tmail.html
echo "</head>" >>/tmp/tmail.html
echo "<p>Transmissionbt v"$torrent_version" finished downloading:</p>" >>/tmp/tmail.html
echo "<p><b>"$TR_TORRENT_NAME"<b></p>" >>/tmp/tmail.html
echo "<p>on `date +\%d/\%m/\%Y` at `date +\%T`</p>" >>/tmp/tmail.html
echo "" >>/tmp/tmail.html
echo "<p>Your awesome router.</p>" >>/tmp/tmail.html
echo "<a href="http://tinypic.com?ref=2zod5ja" target="_blank"><img src="http://i40.tinypic.com/2zod5ja.png" border="0" alt="Image and video hosting by TinyPic"></a>" >>/tmp/tmail.html
echo "</body>" >>/tmp/tmail.html
echo "</html>" >>/tmp/tmail.html
cat /tmp/tmail.html | sendmail -H"exec openssl s_client -quiet \
-CAfile /jffs/configs/Equifax_Secure_Certificate_Authority.pem \
-tls1 -starttls smtp -connect smtp.gmail.com:587" \
-f"$FROM" \
-au"$AUTH" -ap"$PASS" $TO \
rm /tmp/tmail.html
FROM="g***@gmail.com"
AUTH="g***@gmail.com"
PASS="***"
FROMNAME="HSH"
TO="g***@gmail.com"
torrent_name="$TR_TORRENT_NAME"
torrent_version="$TR_APP_VERSION"
logger -t "$0" "Mail sent, about "$TR_TORRENT_NAME""
echo MIME-Version: 1.0 >/tmp/tmail.html
echo Content-Type: text/html >>/tmp/tmail.html
echo "Subject: Download notification" >>/tmp/tmail.html
echo "From: \\"$FROMNAME\\"<$FROM>" >>/tmp/tmail.html
echo "Date: `date -R`" >>/tmp/tmail.html
echo "" >>/tmp/tmail.html
echo "<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">" >>/tmp/tmail.html
echo "<html>" >>/tmp/tmail.html
echo "<head><title></title>" >>/tmp/tmail.html
echo "</head>" >>/tmp/tmail.html
echo "<p>Transmissionbt v"$torrent_version" finished downloading:</p>" >>/tmp/tmail.html
echo "<p><b>"$TR_TORRENT_NAME"<b></p>" >>/tmp/tmail.html
echo "<p>on `date +\%d/\%m/\%Y` at `date +\%T`</p>" >>/tmp/tmail.html
echo "" >>/tmp/tmail.html
echo "<p>Your awesome router.</p>" >>/tmp/tmail.html
echo "<a href="http://tinypic.com?ref=2zod5ja" target="_blank"><img src="http://i40.tinypic.com/2zod5ja.png" border="0" alt="Image and video hosting by TinyPic"></a>" >>/tmp/tmail.html
echo "</body>" >>/tmp/tmail.html
echo "</html>" >>/tmp/tmail.html
cat /tmp/tmail.html | sendmail -H"exec openssl s_client -quiet \
-CAfile /jffs/configs/Equifax_Secure_Certificate_Authority.pem \
-tls1 -starttls smtp -connect smtp.gmail.com:587" \
-f"$FROM" \
-au"$AUTH" -ap"$PASS" $TO \
rm /tmp/tmail.html
I have Entware Transmission installed and configured settings.json to include:
Code:
"script-torrent-done-enabled": true,
"script-torrent-done-filename": "/jffs/scripts/tmail.sh",
Everything was fine till a few days ago.
All script stop working!
A manual calling tmail.sh sends an e-mail but it does not work automatically!
No changes were done in system and/or configs before this happened.
Any idea what is wrong?