Added email authentication and clean function in script

This commit is contained in:
Jorrit Wronski
2015-01-02 13:58:53 +01:00
parent 8df7e56dd4
commit 7901206ae4
2 changed files with 9 additions and 1 deletions

View File

@@ -1211,13 +1211,14 @@ authz_cfg=authz.Authz(
c['status'].append(html.WebStatus(http_port=8010, authz=authz_cfg))
from buildbot.status import mail
from buildbot_private email_auth
#mn = mail.MailNotifier(fromaddr="buildbot@coolprop.org",
# mode = ('problem',)
# )
mn = status.MailNotifier(fromaddr="buildbot@coolprop.dreamhosters.com",
sendToInterestedUsers=False,
mode=('all',),
extraRecipients=["coolprop@jorrit.org"],#,"ian.h.bell@gmail.com"],
extraRecipients=["coolprop@jorrit.org"], #,"ian.h.bell@gmail.com"],
useTls=True, relayhost="coolprop.dreamhosters.com",
smtpPort=587, smtpUser=email_auth['user'],
smtpPassword=email_auth['pass'])

View File

@@ -23,23 +23,30 @@ function git_pull {
function stop {
buildbot stop /home/$USER/buildbot/server-master/
}
function clean {
rm -f /home/$USER/buildbot/server-master/buildbot_private.pyc
}
#
# Check for input
CMD="$1"
if [ "$CMD" = "restart" ]; then
stop
git_pull
clean
start
elif [ "$CMD" = "reconfig" ]; then
git_pull
clean
reconfig
elif [ "$CMD" = "start" ]; then
git_pull
clean
start
elif [ "$CMD" = "stop" ]; then
stop
else
git_pull
clean
start
fi
#