getgrav / grav-plugin-email

Grav Email Plugin
http://getgrav.org
MIT License
37 stars 29 forks source link

Connection could not be established with host #63

Closed zwnk closed 6 years ago

zwnk commented 6 years ago

Hi there,

i'm having an issue with sending the emails via smtp. the mail is working, the server is traceable from the host

the error i get is:

Connection could not be established with host mail.digimapas.cl [ #0]\n
Log data:\n
++ Starting Swift_SmtpTransport\n
!! Connection could not be established with host mail.digimapas.cl [ #0] (code: 0)

my config:

enabled: true
from: email@digimapas.cl
from_name:
to: email@digmapas.cl
to_name:
mailer:
  engine: smtp
  smtp:
    server: mail.digimapas.cl
    port: 465
    encryption: ssl
    user: ******@digimapas.cl
    password: **
  sendmail:
    bin: /usr/sbin/sendmail
content_type: text/html
debug: true

I tested the config on xampp and debian/nginx. Always the same error.

zwnk commented 6 years ago

i changed the the settings to:

enabled: true
from: ***@digimapas.cl
from_name: Website
to: *******@digimapas.cl
to_name: Info
mailer:
  engine: smtp
  smtp:
    server: gator4092.hostgator.com
    port: 587
    encryption: tls
    user: ***@digimapas.cl
    password: 
  sendmail:
    bin: /usr/sbin/sendmail
content_type: text/html
debug: true

and they are working. ssl and port 465 is working with different email clients. Any ideas?

rhukster commented 6 years ago

It's probably a restriction imposed by your web hosting company: https://stackoverflow.com/questions/14176965/swift-transportexception-connection-could-not-be-established-with-host-smtp-gmai

It's really outside the realm of Grav, and even Swift, it's a local network configuration thing.