Mail / sendmail


Is it possible to use sendmail for sending mail in the mail app ?
my configuration block because I do not have a SMTP account, just a sendmail server

Hi @manugre

No, because your mails will be rejected or end up in the recipient’s spam folder if you send them directly via Sendmail.

For your plan to work, you would need a properly set up mail server, which can be done with Sendmail but requires additional configuration, a static IP address and properly configured DNS. You would also need an IMAP server such as Dovecot to manage your mailboxes and serve them to email clients such as Netxcloud Mail.

That’s of course a very simplified explanation. Running your own mail server is a lot more involved than just installing a few services and setting up a few DNS records.

Hence my question. Do you really not have an existing email account that you can use? :wink:

my nextcloud is on the same cloud than my sendmail provider
it should be very more simple

thanks for your answer

What exactly do you mean by a sendmail provider ? Is this some kind of hosting environment that includes a fully fledged mail server?

Well, that depends on where you want the emails to be sent to. If you only want to send them to a local mail server, or one that you have administrative control over, you could get away with just whitelisting the IP of the server that Sendmail is sending the emails from. However, if you also want to send email to third party email servers, you need to set up your own sending email server properly, otherwise you will have trouble getting your emails delivered. This has nothing to do with Nextcloud or Sendmail, it’s just the way the email system works today. If every email server would accept any email, no matter where it comes from, email would be unusable, simply because you wouldn’t be able to find the important messages anymore between all the spam in your inbox :wink:

But again: Don’t you already have an email account somewhere? If so, why not just use that for sending and receiving notifications?

my sendmail work fine
is it a professionnal account on my cloud provider

What ecatctly are you trying to achieve?

Trying to use Nextcloud Mail app without any email account, together with just plain Sendamil, doesn’t make any sense. Nextcloud Mail is not a frontend for Sendmail. It’s a web based SMTP/IMAP client, similiar to Thunderbird or other email clinets. It needs to authenticate with an existing account on a SMTP/IMAP server in order to work. However, Sendmail can be used for the SMTP part of such a mail server, if setup accordingly.

If this is about sending notifications, then in theory you could use Sendmail directly, but that will likely lead to the issues I mentioned above, unless this Sendmail instance is properly setup with a proper email account, or you could use it to relay the emails through an external mail server with a properly setup email account.

Anyways, I suggest you provide us with more details, or better ask your provider on how you can use that Sendmail instance in any meaningful way, because without knowing anything about how this is all set up, this discussion is kind of pointless…