Search code examples
azuresmtpazure-web-roles

Can't connect to SMTP from Azure Web Role


I have a web role that needs to send some e-mails. I have code for this that works locally on my computer, but when I run it on Azure it doesn't work and I just get a "The transport failed to connect to the server." exception. The SMTP server uses SSL and port 465.

Is there some firewall setting that blocks this that I need to fix or could it be something else?


Solution

  • Not really sure about the real cause for this problem, but after we upgraded to Windows Server 2012 on our Azure instances it worked.