Hello how I can send mail with the link of the document in nexcloud I put a mail but doesn´t send.
I tried it now and it works from Nextcloud but it requires working mail. Are your users able to send mail?
Maybe Nextcloud@YOURMAILDOMAIN.TLD is not allowed to send mails via your smarthost?
You may look in /var/log/maillog if a mail was sent and if there was an error.
If I can send the link to a gmail, yahoo or hotmail… can I…?
I have this errors…
Dec 29 15:50:19 sdhg postfix/smtp: connect to gmail-smtp-in.l.google.com[188.8.131.52]:25: Connection timed out
Dec 29 15:50:19 sdhg postfix/smtp: connect to gmail-smtp-in.l.google.com[2607:f8b0:400c:c06::1b]:25: Network is unreachable
Dec 29 15:50:22 sdhg postfix/smtp: connect to alt1.gmail-smtp-in.l.google.com[184.108.40.206]:25: No route to host
Dec 29 15:50:22 sdhg postfix/smtp: connect to alt1.gmail-smtp-in.l.google.com[2a00:1450:400b:c00::1b]:25: Network is unreachable
Dec 29 15:50:37 sdhg postfix/smtp: connect to alt2.gmail-smtp-in.l.google.com[220.127.116.11]:25: No route to host
Dec 29 15:50:37 sdhg postfix/smtp: DA8E1C00A7AB3: email@example.com, relay=none, delay=82657, delays=82584/0.01/73/0, dsn=4.4.1, status=deferred (connect to alt2.gmail-smtp-in.l.google.com[18.104.22.168]:25: No route to host)
It seems you cannot reach the server gmail-smtp-in.l.google.com on port 25. You may change the port to 465 (SSL) or 587 (TLS), see https://www.lifewire.com/what-are-the-gmail-smtp-settings-1170854
Did you block gmail/webmail in some way?
Can you ping gmail-smtp-in.l.google.com? Does it work if you deactivate content filter/proxy?
I can make ping to gmail-smtp-in.l.google.com I don´t have block gmail/webmail.
Did you try to change the port of your smarthost from 25 to 465 or 587?
where is that… I´m sorry…
No problem, it’s in the menu under configuration / email / tab smarthost
One question I need to have a domain or no is importan???
A domain makes mailing much easier. Without domain and MX record you’ll end up using popconnector and smarthost which has some disadvantages and is not recommended. You may try using some dynamic dns service like https://www.dynu.com/ to get a domain with MX record for free but maybe some spamfilters already reject or mark mails from known dyndns IPs.
Here are the docs about how mailing works, what an MX record is etc.
Like @mrmarkuz said port 465 with with SSL should be the right way and I think you have to allow less secure apps as google.