I'm trying to get the nant email task working so that I can eventually email the build log when the build is finished.
 
Here's my build file:
 
<?xml version="1.0"?>
<project name="Email" basedir=".">
<target name="email">
<mail from="[EMAIL PROTECTED]"
 tolist="[EMAIL PROTECTED]" 
 mailhost="[MAILHOST]"
       verbose="true"
      subject="email sent via nant"
      message="is this working even a little bit?!">
 
 <files>
  <include name="C:\...\file.txt" />
 </files>
 
 <attachments>
  <include name="C:\...\nightly.txt" />
 </attachments>
</mail>
</target>
</project>
 
It starts out okay but quickly gives me an error messag:
 
email:
     [mail] Sending mail to [EMAIL PROTECTED].
BUILD FAILED
C:\...\email.build(6,2):
Error sending mail:
Error enountered while sending mail message.
Make sure that mailhost=[MAILHOST] is valid
:
NAnt.Core.BuildException: C:\...\email.build(6,2):
Error sending mail:
Error enountered while sending mail message.
Make sure that mailhost=[MAILHOST] is valid
 ---> System.Web.HttpException: Could not access 'CDO.Message' object. ---> Syst
em.Reflection.TargetInvocationException: Exception has been thrown by the target
 of an invocation. ---> System.Runtime.InteropServices.COMException (0x80040213)
: The transport failed to connect to the server.
 
Assuming that the mailhost is correct, what might I be doign wrong?  I did find a similar question from a few months back in the archive, where Gert wrote:
 
NAnt uses the .NET SmtpMail classes to send email, and these rely on CDOSYS. Perhaps CruiseControl uses a completely managed SMTP implementation.
 
However I don't really understand waht this means...

__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com

Reply via email to