On 4 dic, 21:54, Miguel Lopes <mig.e.lo...@gmail.com> wrote: > Hi Bernado, > > 2010/12/4 Bernardo Botella Corbí <estem...@gmail.com> > > > Hi Miguel, > > > which test did you do from command line? > > does web2py print something? Any error? > > > Try to do the next thing from the command line: > > tail -f /var/log/mail.log > > If I try to send mail from web2py using local resources it fails silently. > I can use a gmail account to send the email it works, so perhaps I'm > configuring gluon.tools.Mail wrongly: > mail.settings.server = 'myIP:25' # your SMTP > server > mail.settings.sender = 'u...@mydomain.pt' # your email > mail.settings.login = 'user:pass' # your > credentials or None 'username:password' > > I'm unsure about mails.settings.server. Is this correct? > > > (if you are in ubuntu/debian, don't know where it would be in other > > distributions...) > > > I'm using Debian Lenny. > > txs, > Miguel
Using Debian Lenny you have probably intalled exim4 as mail server, don't need to install postfix to do the same. Do "dpkg-reconfigure exim4-config" (previously install exim4-config if you don't have it installed) and choose the option of your mail server settings you prefer. Anyway, if you're not going to use it massively, I'd recomend you replacing exim4 by ssmtp (the simplest mail server around), as it's really easy to setup. http://wiki.debian.org/sSMTP To test if it's working, then install mail-utils, and use the command "mail" to send mails and check if they 're received. Then you are sure your server setup is working and you can think of configuring mail in web2py. Regards José L.